Functions
Conditions
9 names in this group.
Each comes with its signature and an example.
ta.crossover
True on the bar where a crosses above b
crossover(a: Source, b: Source): Condta.crossover(fast, slow)ta.crossunder
True on the bar where a crosses below b
crossunder(a: Source, b: Source): Condta.cross
True on a cross either way
cross(a: Source, b: Source): Condta.rising
Higher than each of the previous length values
rising(src: Source, length: number): Condta.falling
Lower than each of the previous length values
falling(src: Source, length: number): Condta.pivothigh
Pivot high (above both sides): its value on the bar right bars later that confirms it, else NaN
pivothigh(src: Source, left: number, right: number): Seriesta.pivotlow
Pivot low, like pivothigh
pivotlow(src: Source, left: number, right: number): Seriesta.barssince
Bars since the condition was last true
barssince(cond: Bool): Seriesta.valuewhen
src on the bar where cond was true (0 = most recent)
valuewhen(cond: Bool, src: Source, occurrence?: number): Series