/** * `pivotHigh` and `pivotLow`. * * The answer lands on the bar `right` bars after the pivot, which is the first * bar on which the pivot is knowable. Returning it at the pivot bar would be a * lookahead: the value would appear on history at a bar where no script could * have had it, and a backtest built on that is a backtest of a strategy nobody * could have run. * * Comparisons are strict on both sides, so an equal neighbour means there is no * pivot there. A run of equal highs has no single highest bar, and picking one * of them would make the answer depend on which end the scan started from. */ import type { Series, StateRecord, Tail, Value } from '../values/index.js'; /** `pivotHigh` and `pivotLow`, answered on the bar the pivot becomes knowable. */ export declare function pivotStep(state: StateRecord, key: string, value: Value, left: number | null, right: number | null, wantHigh: boolean): Value; /** `pivotHigh(src, left, right)`: the value of a local high, from bar `left + right`. */ export declare function pivotHighTail(left: number, right: number): Tail; /** `pivotHigh(src, left, right)` over a whole series. */ export declare function pivotHigh(src: Series, left: number, right: number): Value[]; /** `pivotLow(src, left, right)`: the value of a local low, from bar `left + right`. */ export declare function pivotLowTail(left: number, right: number): Tail; /** `pivotLow(src, left, right)` over a whole series. */ export declare function pivotLow(src: Series, left: number, right: number): Value[]; //# sourceMappingURL=pivots.d.ts.map