| stevehopwoodforex.com https://www.stevehopwoodforex.com/phpBB3/ Print view |
|
| Empty4 Coding Question https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?t=2655 |
Page 1 of 1 |
| Author: | Jetskull [ Fri Jul 05, 2013 1:08 am ] |
| Post subject: | Empty4 Coding Question |
Hi, Can anyone show me how to find or detect with code if I get a New 3 Day Low or High New 3 Week Low or High New 3 Month Low or High in Empty4 Empty4 Thanks |
|
| Author: | phil_trade [ Fri Jul 05, 2013 4:47 am ] |
| Post subject: | Re: Empty4 Coding Question |
Hi please have a look at MQL doc. for iHighest()/iLowest(). If it return 0, the current bar is a recent High/Low int iHighest( string symbol, int timeframe, int type, int count=WHOLE_ARRAY, int start=0) Returns the shift of the maximum 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 the 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: double val; // calculating the highest value on the 20 consequtive bars in the range // from the 4th to the 23rd index inclusive on the current chart val=High[iHighest(NULL,0,MODE_HIGH,20,4)]; |
|
| All times are UTC | Page 1 of 1 |
|
Powered by phpBB® Forum Software © phpBB Limited |
|