Do you have a code which functiones (regardless of indicator). I need to find principle for "candle crossing"...
//--Below the criteria which check new bar started
//----closing area s new bar
//----closing start area
Actually I ran it on M1 DAX and on Tester.
Buy does not occur in whole year even with RSI overSold value 45
Thank you a lot in advance
Why are you calculating the RSI values every tick when you are only using them when a new bar forms?
Buffers are used in indicators, not EAs, naming an array with "Buffer" in its name can be confusing. Why use an array anyway, you only check 2 values.
You can cut out
//---- We here below fill buffer with RSI values
and just use
int OneCandleAgoCloseRSI = iRSI(NULL,0,RSIPeriod,ApplyTo,1);
int TwoCandlesAgoCloseRSI = iRSI(NULL,0,RSIPeriod,ApplyTo,2);
int OneCandleAgoCloseRSI = RSIBuffer;
int TwoCandlesAgoCloseRSI = RSIBuffer;
Your code should place trades unless you have something like incorrectly sized array
YOUR SOLUTION WORKS!!! Thank you a lot!!!
Pitty this forum does not have points,so I could give you highest grades
Is there anything I can do for you?
You saved me days od researching. Maybe you have email?
To add comments, please log in or register