Skip to content
All library documents

Range-Bound Swing Trading with a Trend Filter and Stochastic Entries

Article ProRealCode

Summary

The strategy first classifies market conditions with a linear-regression slope statistic, treating readings below a stated threshold as a no-trend phase. During that phase, a smoothed stochastic turning upward from a low level triggers a long stop entry above the bar; a downward turn from a high level triggers a short stop entry below it. Pending entries expire after a short bar limit. Stops are based on recent highs or lows, with a maximum distance, and a SuperTrend reversal exits open positions.

The post says the approach appears to have positive results across different indices and time frames after optimizing the observation period. It does not report performance figures, test dates, costs, or robustness checks, so that claim cannot be assessed from the document. The code also specifies contract size, trading-day exclusions, and instrument point values; these implementation settings may need adaptation to the market and platform. Parameter optimization creates a risk of overfitting.

Key ideas

  • A regression-based statistic gates swing entries to periods classified as having no trend.
  • Smoothed stochastic turns from low and high levels trigger long and short stop orders.
  • Entries expire after a specified bar limit, and stops use recent price extremes with a cap.
  • SuperTrend reversals close positions, while the claimed positive results are unsupported by detailed test evidence.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.