Sinyal untuk membuka order adalah perpotongan RSI dari level atas atau bawah.
Level diatur dalam parameter.
eksternal ENUM_TIMEFRAMES jangka waktu_RSI = 60;
eksternal int periode_RSI = 14;
eksternal int level_beli = 30;
eksternal int level_sell = 70;
eksternal int MinStep = 20;
lot ganda eksternal = 0.1;
eksternal ganda K_Lot = 1.5;
extern int Takeprofit = 50;
extern int Magic = 0;
extern int DigitsLot = 2;
extern int slippage = 3;
Contoh
If the indicator crosses the level level_buy = 30 from bottom to top, then the buy position is opened. If the price did not reach TP and a new buy signal arrived, the adviser checks the current price level and, if the price is lower on MinStep, it opens a second trade.
TP of both trades is averaged and set from the point of their total breakeven. The same happens with the positions for sale.
The parameters in the advisor must be selected for each tool separately. This is easiest to do in the terminal optimizer. If you have questions, ask.
Below is an example of the work of the adviser. EA RSI Averange hands first - opening the first position manually. The rest are already opened by the adviser.