Hi everyone,
Is it possible to code something happening in the last 5 periods???
Example:
IF MM6 Crosses over MM5 (in any of the last 5 candles) AND close>MM6 THEN
I am trying to BUY when two or more conditions occur, but in some cases all of them happen within the last 3-5 candles.
Thanks in advance,
Juan
if condition1 then
signalindex=intradaybarindex
endif
if condition2 and intradaybarindex-signalindex<=5 then
buy 1 contract at market
endif
This should do it.
Despair,
Thanks so much for your help. It works the way you said.
I am learning a lot from these contributions.
Regards,
Juan
You may try this one:
.
.
.
IF summation[5]((Average[6] CROSSES OVER Average[5]) AND (close > Average[6])) > 0 THEN
.
.
.
ENDIF
.
.
.
Roberto