NinjaScript > Language Reference > Data >

LowestBar()

Print this Topic Previous pageReturn to chapter overviewNext page

Definition
Returns the number of bars ago the lowest price value occured for the lookback period.
 

Method Return Value

An int value that represents number of bars ago.

 

Syntax
LowestBar(IDataSeries series, int period)

 

Parameters

period

Number of bars to check for the test condition

series

Any DataSeries type object such as an indicator, Close, High, Low, etc...

 

 
Examples

// Prints out the number of bars ago for the lowest SMA(20) value of the current session
Print(LowestBar(SMA(20), Bars.BarsSinceSession - 1).ToString());