Could you code an expert advisor to open and close trades according to the following conditions:
Open buy
After x number of bullish candles.
Open sell
After x number of bearish candles.
There should be an option to close trades when there is an opposite signal .
Regards.