ATR Trailing Stops with VWMA Smoothing for Directional Signals
Summary
This indicator and trading script uses a 21-period ATR multiplied by 6.3 to set a trailing stop that follows price direction. Its position state changes when price crosses the prior trailing-stop level: a move above it produces a long state, while a move below it produces a short state. The script colors bars and marks the resulting buy or sell signals, then submits entries in the corresponding direction. It also calculates a volume-weighted moving average over a configurable smoothing period, defaulting to 100, and plots its average with the trailing stop.
The document includes source code and published test settings for BTC-USDT futures over roughly one month, using two-hour bars with a 15-minute base period. It reports no performance statistics, so the settings alone do not demonstrate effectiveness. The implementation has inconsistencies: the alert labels appear reversed, repeated alert conditions are present, and the smoothing line does not drive entries. The large ATR multiplier may also make directional changes infrequent; results will depend on the market and parameters.
Key ideas
- The trailing stop is based on ATR multiplied by a configurable factor, defaulting to 6.3.
- Price crossing the prior stop level determines whether the script enters a long or short state.
- A 100-period VWMA-based line is plotted but does not affect the entry conditions.
- The published test configuration uses BTC-USDT futures and two-hour bars, without reporting performance results.
- The alert labels and repeated alert conditions appear inconsistent with the position signals.
Tags
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.