Fitting Regression Trend Channels to Price Pivot Points
Summary
This indicator method automates trendline drawing by locating pivot highs and lows, fitting separate linear regressions to those points, and iteratively retaining points on the relevant side of each fitted line. The resulting upper and lower lines aim to follow price extremes rather than the center of all observations. Standard deviation offsets create additional channel boundaries, and the indicator projects the lines forward for chart interpretation.
The document describes possible uses: trading in the direction of a channel, watching for closes beyond an outer band, and placing trailing stops near an opposing line or band. Parameters control pivot strength, regression lengths, iteration count, point-count limits, a fit-quality threshold, projection distance, and band width. The code draws only on the latest bar to reduce platform workload. No test results or objective evidence of signal quality are supplied; parameter choices can change the identified pivots and channel, and a projected line is a calculation rather than a guarantee of future price behavior.
Key ideas
- The method detects swing highs and lows using configurable left and right lookback periods.
- Separate regressions are iteratively refitted to upper and lower pivot subsets.
- Standard deviation offsets form outer channel boundaries around the fitted trendlines.
- The channel is proposed for trend following, breakout observation, and trailing-stop placement.
- The document presents implementation logic but no backtest or evidence of predictive accuracy.
Tags
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.