Download MetaTrader 5
To add comments, please log in or register
Share your knowledge. Become a well-known developer!
rajre72
24
rajre72 2015.10.01 16:09 

hi iam started learnig to write a code

need to write this 

if previous 1,2,3 bars highest of high value should be higher than the previous 4,5,6, bars lowest of low .

anybody help me !!

whroeder1
13627
whroeder1 2015.10.02 00:06  
rera7: iam started learnig to write a code
You have only three choices: Search for it, learn to code it, or pay someone. We're not going to code it FOR you. We are willing to HELP you when you post your attempt (using SRC) and the nature of your problem.
Keith Watford
Moderator
7960
Keith Watford 2015.10.02 02:09  
rera7:

hi iam started learnig to write a code

need to write this 

if previous 1,2,3 bars highest of high value should be higher than the previous 4,5,6, bars lowest of low .

anybody help me !!

Look in the Editor help documentation for High and iHigh
rajre72
24
rajre72 2015.10.02 12:44  

thanks for your suggestions. after going through iHighest,iLowest  functions .. this is what i got

    > if { previous 1,2,3 bars highest of high value > previous 4,5,6, bars lowest of low }

if( High[iHighest(NULL,0,MODE_HIGH,3,1)] > Low[iLowest(NULL,0,MODE_LOW,3,4)])

 is this correct ?  added 4 in above function ,so it will start from previous fourth bar!

Keith Watford
Moderator
7960
Keith Watford 2015.10.02 12:55  
rera7:

thanks for your suggestions. after going through iHighest,iLowest  functions .. this is what i got

    > if { previous 1,2,3 bars highest of high value > previous 4,5,6, bars lowest of low }

 is this correct?

Looks correct to me
rajre72
24
rajre72 2015.10.02 13:09  
Thank you sir.
/
To add comments, please log in or register