Oberon Bars MT5

Oberon Bars MT5

21 июля 2022, 00:52
Aliaksandr Chupryna
0
234

Expert Advisor "Oberon Bars MT5".

The signal to open positions is the data of the "Correction_Bars", "Trend_Size" and "Correction_Size" parameters. Signal to close positions - "TakeProfit":

1_1

                                                                   EXAMPLE OF EA OPTIMIZATION                                                                      

By optimizing the Expert Advisor on different timeframes and in different ranges of parameters, you can create several (and more) strategies for yourself with different input data. At the end of the blog, ".set" files are attached, which can be used as a basis for optimization and edit the data of only those currency pairs that are not suitable for the given conditions of the trading account.

   ACT 1   

We will optimize each block separately. Disable all characters except the first.

1_2

   ACT 2   

Turn on the optimization mode.

2-1

To reduce the optimization time, we will limit the results we need to a drawdown (about 50) . To do this, put Auto_Lot=true, Deposit=500, BalanceForAdd=50. As a result, only those testing results will remain in which, with Auto_Lot=false, the maximum drawdown will be about BalanceForAdd or less. Necessarily Exponent_Symbol=1. Set optimization parameters.

2_2

   ACT 3   

We look at the number of test options.

3-1

Choose an optimization option. Option 1( Slow complete algorithm) will show us all the results (which is desirable). But if the number of testing options is very large, then option 2( Fast genetic based algorithm) can be chosen. Run the optimization.

3_2

   ACT 4   

From the optimization results, select one of them and start testing.

4_1

4-2

   ACT 5   

Now we switch to the "Auto_Lot = false".

5_1

We get a result that suits us.

5_2

5_3

   ACT 6   

Don't forget to save in "file.set" .

6_1

   ACT 7   

Then we repeat the same actions with other currency pairs. You can check each time their joint work.

7_1

   ACT 8   

After optimizing all symbols, we finally test all blocks together ("Trade=true" for all symbols). We see the result that reflects the essence of the adviser - the profit is summed up, but the drawdown has not changed much (increased by 2 times). To do this, when choosing optimization results, you should try to choose results with an average number of deals and a small TakeProfit (so that the positions of different symbols overlap less often).

8_1

   ACT 9   

You can stop at this, or you can accelerate the dynamics of profit growth. Enable Auto_Lot=true . Let's take a deposit of 500. BalanceForAdd=150 (every 150, lot will increase by 0.01)

                                                                    HOW "Limit_Max_Lot" WORKS                                                                 

On the tested account, the broker set the maximum trade volume limit MaxLot=500. If lot=500 for the first trade in a position, then lot>500 may be required for the next trades in this position and the EA will set the maximum possible lot=500. Therefore, there are drawdowns.

10_1

If Limit_Max_Lot=true, the first trade in a position will not exceed MaxLot/100.

10_2

Файлы: