The line cannot predate pivot confirmation

A pivot of length N is known only after N bars have formed to its right. The line may anchor at the earlier pivot bar for geometry, but it was not an available decision input at that origin. A historical review must timestamp both origin and confirmation.

The default swing strength is 10. The short tier uses that length, the medium tier twice that length, and the long tier four times that length, capped at 200. With all three tiers enabled on both sides, the script can maintain up to six active lines: three descending and three ascending.

The candidate search is finite

For each side and length tier, the engine searches a configurable number of confirmed pivots; the default is 10. High pivots can form descending candidates and low pivots ascending candidates. Optional minimum anchor span and touch requirements can further reduce the set.

Anchor price can use the pivot wick or body, while pivot detection itself remains wick-based. A pair-exclusion rule prevents the same anchors from being duplicated across tiers, so the displayed set is not simply six copies of one geometric line.

Every pair must survive four validity checks

First, the anchors must be on the same side. Second, they must be progressive: the second high must be lower for a descending line, and the second low higher for an ascending line. Third, no intermediate bar may pierce the segment beyond the configured ATR-based tolerance. The default pierce tolerance is 0.25 ATR.

Fourth, no bar after the second anchor through the current bar may have violated the projected line under the selected wick-or-close basis and violation tolerance. The checks are refusal rules: failing one disqualifies the pair rather than reducing a score.

Selection is proximity, not confidence

The engine evaluates all qualifying pairs for a side and tier, projects each candidate to the current bar, and selects the line whose projected price is nearest the current close. Nearest is a display-selection rule after validity; it does not rescue an invalid pair.

Touch count records contacts inside an ATR-based tolerance band around the projected line. It is descriptive history, not a strength score. Several touches in one congestion are not independent observations, and a higher count does not imply a higher probability of holding.

Violation and age retirement are different exits

A live line is violated only on a confirmed bar under the selected wick-or-close rule. Violated lines can be dimmed and retained for review, and the published script exposes separate ascending and descending violation alerts.

A line also retires when its anchor exceeds the configured “Bars to Apply” limit, which defaults to 300. Age retirement is not a violation and does not fire a violation alert. Turning a line family off deletes those lines rather than preserving them as retired geometry.