Previous High/Low

Previous High/Low connects the high and the low of the previous bar — a two-level channel, each side widened by a vertical shift in points. Orders at the previous extremes are the classic stop orders for a range breakout.

Role in the strategy

SlotAvailableRole
Entry PointYesEnters at the previous bar's high or low.
Entry RuleYesFilters entries by the bar open or the bar close relative to the channel.
Exit PointYesExits at the previous bar's high or low.
Exit RuleYesTriggers exits by the bar close relative to the channel.

As a point the two channel levels are the pending order prices; as a rule the indicator contributes only the long/short signal arrays. It uses the same band logic as Bollinger Bands: Upper Band is the previous high plus the shift, Lower Band the previous low minus the shift.

As an exit point it places resting orders the bar reaches, so it carries no Exit Rules. Only Bar Open and Bar Close allow them.

Logic rules

  • Entry Point: Enter long at Upper Band, Enter long at Lower Band.
  • Exit Point: Exit long at Upper Band, Exit long at Lower Band.
  • Rule slots:
RuleLong order priceShort order price
Enter/Exit long at Upper BandPrevious High + shiftPrevious Low − shift
Enter/Exit long at Lower BandPrevious Low − shiftPrevious High + shift
  • Entry Rule / Exit Rule:
RuleLong signal is 1 whenShort signal is 1 when
The bar opens above Upper Bandbar open is above the previous highbar open is below the previous low
The bar opens below Lower Bandbar open is below the previous lowbar open is above the previous high
The bar opens below Upper Band after opening above itbar open fell back below the previous highbar open rose back above the previous low
The bar opens above Upper Band after opening below itbar open rose above the previous highbar open fell below the previous low
The bar opens below Lower Band after opening above itbar open fell below the previous lowbar open rose above the previous high
The bar opens above Lower Band after opening below itbar open rose above the previous lowbar open fell below the previous high
The bar closes above Upper Bandbar close is above the previous highbar close is below the previous low
The bar closes below Lower Bandbar close is below the previous lowbar close is above the previous high
The bar closes below Upper Band after closing above itbar close fell back below the previous highbar close rose back above the previous low
The bar closes above Upper Band after closing below itbar close rose above the previous highbar close fell below the previous low
The bar closes below Lower Band after closing above itbar close fell below the previous lowbar close rose above the previous high
The bar closes above Lower Band after closing below itbar close rose above the previous lowbar close fell below the previous high

The six The bar closes lines are exit-only (Exit Rules). The six The bar opens lines always read the previous bar's channel whatever the slot's execution time: a channel that contains its own bar would make them structurally false. This is the same pin the Donchian Channel uses.

Parameters

ParameterTypeDefaultRangePurpose
Vertical shiftnumber0−2000 to 2000Points added above the previous high and subtracted below the previous low

Calculation

  1. The read bar's high and low are taken from the previous bar;
  2. the upper line is previous high + shift, the lower line previous low − shift, both in points;
  3. the channel is drawn on the main price chart as two level lines.

Backtesting

  • As an entry point the pending orders sit at the two channel levels; the long and short levels differ, so both orders can be placed and the intrabar interpolation decides which side fills first.
  • As a rule the indicator contributes only long/short signals. Comparisons use the standard dead zone (SIGMA = 0.000001).
  • A level the price gapped across moves to the bar open, so an order is never missed on a gap.