Table of Contents

Monte Carlo

Monte Carlo is the best tool for testing the strategy robustness. When you create a strategy, you see its backtest statistics. However, the strategy might be over-optimized (curve fitted). The goal of the Monte Carlo tool is to verify that the strategy is not over-optimized. This tool allows you to apply random changes to the market data, the execution of the strategy and the numeric parameters of the strategy indicators.

If you make minor changes to the strategy and its environment, and the strategy continues to have good profits, this means that the strategy has a good chance of making money on the real market.

On the other hand – if you make some minor changes and the strategy profits crumble, it means that this strategy is over-optimized and thus, it is a bad choice to trade.

When you run the Monte Carlo tool, you actually do not run just a single test but 20 (by default) tests. Each test is random. It can use one or more simulations.

Simulations

Here you can choose the simulations that will be used in the Monte Carlo tests. You select optional parameters for each simulation from the Options tab.

Market variations

Execution problems - These are related to problems when executing the signals sent from the Expert Advisor to the broker.

Strategy variations

Simulations chart

By the default running the Monte Carlo tool will run 20 tests with randomized data. The randomization of the data will be done according to the Simulations checklist and the values in the Options tab.

Each of the tests will be drawn on the Simulations chart with a colored line. You can see how the lines are grouped and what the end result is of each backtest. This can easily show how robust the strategy was and how destructive the randomized environment and data turned out to be for it.

Confidence table

This table shows different statistics from the testing.

The first row shows the initial strategy (the one you are using the Monte Carlo tool on).

The first column shows the percentage of tests that showed results better than the current row. “Confidence” column shows the probability for the profit to be higher than the “Net Balance” value.

For example in the screenshot above, you see the lowest row shows 100% confidence. This “assures” us that if we have traded this strategy, we could expect it to make at least 351 over the given period. This of course if based on 20 random tests and has a great risk of being incorrect as soon as we run the tests anew or trade the strategy on a live account.

The tool is only named “Confidence Table” to be easily recognized by traders who used it in other software. However neither here, nor in other software is the Confidence Table about confidence. It's only a tool that groups the results from the random tests in the past and shows us how many of them succeeded and how much the succeeded. This means that if you rerun the Monte Carlo tests, you almost certainly won't get the same results.

Monte Carlo uses historical data therefore it cannot guarantee or predict the strategy's future success. At best it can only point out if a strategy is over-optimized for the market data we have.

Settings

All the options below will apply to the tests only if they are enabled from the Simulations checklist

Market variations

Execution problems

Strategy variations

Validation

When running the Reactor or the Validator Monte Carlo testing is present in the Robustness testing section.

The Validated tests setting uses the Validation settings in the Monte Carlo tool here.

These are very similar and work in the same way as the general Acceptance Criteria for the collection works.

In the above example a strategy will be considered to have passed the Monte Carlo validation only if at least 80% of the tests pass.