INDICATORS · LINREG CHANNEL

Linear Regression Channel in Crypto: Why the Value Changes Before Candle Close

A regression channel draws a fitted line through N bars with bands a set number of standard deviations away. On the live bar, the whole channel re-fits.

Short answer

A linear regression channel fits a least-squares line through the last N closes and adds parallel bands at ± k standard deviations of residuals. With every live tick, the line's slope, intercept and residual deviation are recalculated, so the entire channel — including its left end — shifts. Touches of the band seen intrabar may not exist on the closed bar, and past channel drawings differ from the channel visible at the time. Record channel values at bar close.

Which part of Linear Regression Channel uses the live bar

ComponentUses current bar?Effect intrabar
Fitted lineYesWhole line re-fits
Residual std devYesBand width changes
Left end of channelYesMoves too

Because the channel is re-fitted, it is not a fixed drawing: the channel shown today over last week's bars is not the channel a trader saw last week.

Review Linear Regression Channel in Crypto with bar replay before using it live.

Open ChartsPod replay

How much it moves inside one bar

Linear Regression Channel during one bar (illustrative)Linear Regression Channel during one bar (illustrative): OPEN: Upper band 61,200; MID: Spike: line steepens, band 61,450; LATE: Fade; CLOSE: Band 61,260.OPENUpper band 61,200MIDSpike: line steepens, band61,450LATEFadeCLOSEBand 61,260
Only Linear Regression Channel's closing value is kept in history. Original ChartsPod editorial graphic.
Illustrative intrabar range of Linear Regression Channel vs its closed valueIllustrative intrabar range of Linear Regression Channel vs its closed value: Upper band intrabar shift ($) 250 ; Typical closed-bar shift ($) 60 .ILLUSTRATIVE INTRABAR RANGE OF LINEAR REGRESSION CHANNEL VS ITS CLOSED VALUEUpper band intrabar shift ($)250Typical closed-bar shift ($)60
How far Linear Regression Channel travels inside a bar versus between bars. Original ChartsPod editorial graphic.

Rules

Linear Regression Channel signal hygieneLinear Regression Channel signal hygiene: Signals on closed bars; Bar-close alerts; Backtest uses the same rule; Live value labelled provisional; Settings identical across chart and alerts.LINEAR REGRESSION CHANNEL SIGNAL HYGIENESignals on closed barsBar-close alertsBacktest uses the same ruleLive value labelled provisionalSettings identical across chart and alerts
Closed values are what history shows. Original ChartsPod editorial graphic.

Related: Linear Regression Slope in Crypto: Why the Value Changes Before Candle Close (slope).

Put Linear Regression Channel in Crypto next to price, flow and positioning in one workspace.

Open a ChartsPod workspace

Questions readers ask

Why does the regression channel move?

It is re-fitted on every tick of the live bar.

Is a past channel what traders saw?

No; it was re-fitted since.

How do I backtest it?

Use values computed at each bar's close.

Sources and methodology

Indicator formulas are standard definitions; live-versus-closed behaviour follows TradingView's repainting documentation. Values in examples are illustrative.

  1. TradingView Pine Script: Repainting — live vs historical calculation.
  2. ChartsPod indicator reference — indicator calculations.

This article explains research tools and workflows. It is not financial advice, does not recommend buying or selling any asset and does not predict prices. Crypto derivatives carry a risk of rapid and total loss of margin.

CHARTSPOD EDITORIAL EDITION · RESEARCH AND EDUCATION ONLY · NOT FINANCIAL ADVICE.