AND BLOCK
-
Hello , Good day
Can you please explain how i can link conditions with the AND block for example if 9 ema cross above 50 ema and if 9 ema cross above 50 sma it should buy
thanks
https://fxdreema.com/shared/0KAFCfCA -
This is not how the and block works, you don't need, just connect blocks in a row, you use and with 2 blocks, to do this you need to setup separate trees, so when a cross happens the EA is waiting for the next.
-
@codex3024
I think you really mean OR. If it is an AND, there mean both crossovers occur at the exact same bar! Is it really what you want? -
@jstap hello, i tried that but it didn't work
https://fxdreema.com/shared/bAKsSdzGd
it doesn't open a trade at all -
@sktsec i want it to open a trade when the 9ema is above 200 sma and 200 ema
https://fxdreema.com/shared/bAKsSdzGd -
@jstap ok please how
https://fxdreema.com/shared/WzSpxnjAb
i tried this but it only use the 200 SMA not both
-
Try this, 9>200, 9x>50, no trade on top, buy on bottom, back test with this to see what happens.
-
@jstap ok let me try
-
@jstap didn't work 9 > 200 sma, 9x> 200 ema
i think it has to do with the AND block or what do you think?

-
@jstap i used another platform it worked fine only problem is it keeps on opening position even after hitting TP or SL
-
You don't need the and block, https://fxdreema.com/shared/hKIu3vkvb
-
To stop a trade you need to add a condition that will prevent, something like, under trade turn flag false, check above buy/sell, once per daily bar turn flag to true.
-
@jstap i'm using 200 SMA and 200 EMA not 200 and 50
-
The choice is yours, the biggest difference is LW vs Smooth, all in all though the difference for testing isn't a lot.
-
@jstap are you suggesting i use LW and Smoothed ?
-
No I am suggesting you use whatever you want.
-
@jstap but none is working
-
Add a shared link and say what it is that's not working
-
@jstap can you help with an example of the block arrangement ?
-
You have that above