OPEN-SOURCE SCRIPT

Adaptive Trend Step[NeuraAlgo]

914
Adaptive Trend Step[NeuraAlgo]

Overview

Purpose / Description
The Adaptive Trend Step indicator is designed to track price trends while adapting to market volatility 🌊. It uses adaptive volatility scaling ⚖️ to create a dynamic step-like trend line 📈📉, helping traders identify uptrends 🔵, downtrends 🟠, and neutral phases 🟣. The line adjusts automatically depending on market volatility, making it responsive in fast markets ⚡ and smooth in quiet markets ✨.

스냅샷


How It Works
Efficiency Ratio (ER) ⚡
• Measures the strength of the current price movement relative to recent price changes.

Formula:
ER = (absolute change over 'length') / (sum of absolute changes over 'length')
• ER ranges 0–1, indicating strong trends (closer to 1) or sideways markets (closer to 0).
Adaptive Standard Deviation (Adaptive Dev) 📏
Combines fast and slow standard deviations, weighted by ER:
Adaptive Dev = ER * fast_dev + (1 - ER) * slow_dev
• Creates a tight threshold in strong trends ⚡ and wider threshold in sideways markets 🌫️.


Trend Calculation (trend_val) 🔄
• Compares price against the previous trend ± adaptive deviation:
○ Price > previous trend + adaptive_dev → trend moves up 🔵
○ Price < previous trend - adaptive_dev → trend moves down 🟠
○ Otherwise → trend stays neutral 🟣

Smoothing ✨
Uses a weighted average to smooth the trend:
trend_smooth = trend_val * smooth_factor + previous_trend_val * (1 - smooth_factor)
• smooth_factor controls responsiveness vs. smoothness.
Trend Coloring 🎨
• Uptrend 🔵, Downtrend 🟠, Neutral 🟣

Plotting 🖌️
• Thin line with diamond steps 💎 for precision.
• Thick semi-transparent line 🌫️ for trend highlighting.
Alerts 🚨
• Triggers uptrend ⬆️ or downtrend ⬇️ alerts in real-time.

Inputs / Settings

Main Settings 🛠️
• ER Length – Bars to calculate Efficiency Ratio (default 100)
• Fast StdDev Length – Fast volatility length (default 50)
• Slow StdDev Length – Slow volatility length (default 200)
• Source – Price source (default close)
• Smoothing Factor – Smoothness control (default 0.5, step 0.05)

Art / Visual Settings 🎨
• Up Trend Color 🔵 – Uptrend color (default blue)
• Down Trend Color 🟠 – Downtrend color (default orange)
• Neutral Trend Color 🟣 – Neutral color (default purple)

Use Cases 💡
• Identify current trend direction and reversals 🔄
• Determine entry & exit points 🎯
• Combine with other indicators (RSI, MACD) for trade confirmation ✅
• Adaptable to volatile ⚡ or sideways 🌫️ markets

In short:
The Adaptive Trend Step is a dynamic trend-following tool 📈 that adjusts automatically to market volatility ⚖️, helping traders spot trends 🔵🟠🟣 without being too noisy during sideways movements 🌊.

면책사항

해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.