Assume 3 bars: Bar [2], Bar [1] and Bar [0] (Current).
Is the following "stop_low()" function correct to find the lowest low of bar [2] and [3] ?
double stop_low = iLowest(Symbol(),0,1,2,1);
------------------------------------------------------------
Reference:
int iLowest( string symbol, int timeframe, int type, int count=WHOLE_ARRAY, int start=0) Returns the shift of the least value over a specific number of periods depending on type. Parameters:
symbol - Symbol the data of which should be used to calculate indicator. NULL means the current symbol. timeframe - Timeframe. It can be any of Timeframe enumeration values. 0 means the current chart timeframe. type - Series array identifier. It can be any of Series array identifier enumeration values. count - Number of periods (in direction from the start bar to the back one) on which the calculation is carried out. start - Shift showing the bar, relative to the current bar, that the data should be taken from. Sample:
// calculating the lowest value on the 10 consequtive bars in the range
// from the 10th to the 19th index inclusive on the current chart
double val=Low[iLowest(NULL,0,MODE_LOW,10,10)];
Is the following "stop_low()" function correct to find the lowest low of bar [2] and [3] ?
double stop_low = iLowest(Symbol(),0,1,2,1);
------------------------------------------------------------
Reference:
int iLowest( string symbol, int timeframe, int type, int count=WHOLE_ARRAY, int start=0) Returns the shift of the least value over a specific number of periods depending on type. Parameters:
symbol - Symbol the data of which should be used to calculate indicator. NULL means the current symbol. timeframe - Timeframe. It can be any of Timeframe enumeration values. 0 means the current chart timeframe. type - Series array identifier. It can be any of Series array identifier enumeration values. count - Number of periods (in direction from the start bar to the back one) on which the calculation is carried out. start - Shift showing the bar, relative to the current bar, that the data should be taken from. Sample:
// calculating the lowest value on the 10 consequtive bars in the range
// from the 10th to the 19th index inclusive on the current chart
double val=Low[iLowest(NULL,0,MODE_LOW,10,10)];