RoboForex – Professional services on Forex market

How to test Expert Advisors - a comprehensive MetaTrader 4 manual

Как тестировать советники - подробная инструкция для MetaTrader 4



More →
How to get a license

for free!

More →
Crypto exchange
Crypto Wallets
More →

Forex – Crypto Advisor VR Black Box
Forex – Crypto Advisor VR Black Box

Icon of the program version Version: 22.021

Icon program update date Updated: 24.02.2022

Icon date the program was added Added: 22.08.2017

License: Paid-Free

One-time purchase: 122$85$

Rent: from 30$from 21$

The trading strategy is similar to the swing strategy, if we made a wrong purchase, then we make a sale. Algorithms for protection against high-risk situations is an interesting feature of this program. VR Black Box uses real Stop Loss and Take Profit levels, and can also use virtual levels, while using real levels, the expert adviser hides virtual levels. I started developing this trading strategy in 2009. A large number of improvements and modifications have been implemented in the VR Black Box expert adviser over this more than ten-year period.

VR Locker - successful lock trading
VR Locker - successful lock trading

Icon of the program version Version: 22.040

Icon program update date Updated: 11.04.2022

Icon date the program was added Added: 30.08.2017

License: Paid-Free

One-time purchase: 122$85$

Rent: from 30$from 21$

The program trades according to a unique logic, the task of which is not just to fix the profit, but also to use the accumulated profit as a safety cushion, which significantly reduces the drawdown on the balance.

VR Lollipop – trend collecting trading robot
VR Lollipop – trend collecting trading robot

Icon of the program version Version: 24.041

Icon program update date Updated: 08.04.2024

Icon date the program was added Added: 28.10.2022

License: Paid-Free

One-time purchase: 149$89$

Rent: from 30$from 15$

Trading robot VR Lollipop is an automated trading strategy designed for trading on trend movements of any financial instruments. The main task of the Expert Advisor is to accumulate profitable positions.

Written and compiled scripts, so-called Expert Advisors, can be run on any MetaTrader 4 terminal. This factor has created a whole market of user programs, distributed both free of charge and on various terms of a one-time payment or subscription. Today, you can find more than one hundred thousand such programs on the Internet.

In theory, Expert Advisors should contain an open and repeatedly tested on demonstration trades and in real conditions strategy, and test results are usually attached to the program. It turns out that traders acquire fully automatic, already tested algorithms.

In practice, this is not always the case, and since robots get access to a real deposit, it is very important to make a rapid assessment of the advisor purchased at the first stage of the choice, regardless of the delivered and advertised results.

There are only two ways to check the program for compliance with the trading strategy, for code errors and for real profitability. Any MetaTrader user can check the effectiveness of the program via the strategy tester or run the program on a demo account.

Let's consider both ways of testing in detail.

Preparing the MetaTrader 4 terminal for Expert Advisor testing

A custom script with a coded strategy for MetaTrader 4 is a mql4 or ex4 file. The trader should ensure the correct path when installing an Expert Advisor, so that it can be found and run on the MetaTrader 4 platform without problems.

The installation looks like an ordinary file copying, but there is one important feature — the folder for placing the Expert Advisor files is opened via the running trading terminal.

The first step of the trader is to make sure that the EA files are in fact intended for MetaTrader 4 by checking the extension (it should be mql4 or ex4). For the sake of providing an example, we will install VR Smart Grid robot, which consists of a single file.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

The second step is the MetaTrader 4 launch

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

The third step is to open the Expert Advisor installation folder via the “File” -> “Open Data Folder”.

After this operation, the folder window will open as usual.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

Indicators, Expert Advisors, auxiliary libraries, presets, templates and other files related to the custom configuration of the platform are located in the MQL4 folder. It is enough to open it to immediately find where to copy the Expert Advisor files due to corresponding folder names.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

Step four - distribute the Expert Advisor files to the appropriate folders, following the recommendations attached to it or relying on extensions:

  • mql4 and ex4 — to the Experts directory
  • dll libraries — to the Libraries folder
  • presets files — to the Presets folder

In the example, we will copy the VR Smart Grid file to the Experts folder.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

If the Expert Advisor is installed correctly, its name will appear in the Navigator, after MetaTrader 4 restart.

The final stage before testing, is ticks history downloading. Define the instruments you want to work with and press F2.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

Select the desired currency pair or CFD contract in the Quotation archive window, and then click the Download button. The tick history will be downloaded, the progress will be marked by the green bar at the bottom of the Quotation Archive window.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

If the history is already loaded into the Metatrader 4 terminal and the broker's servers do not contain new data, a message will appear with a suggestion to recalculate timeframes. Just in case it is better to make the suggested update of tick data.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

The downloaded archive of quotations will provide the strategy tester with database for modeling (restoring) candles when recreating the trading history.

Using the Strategy Tester

The first way to test Expert Advisors - using the Strategy Tester - is faster, but it does not provide accurate results. This is a great option for pre-testing the script.

Preparation of Metatrader 4 Strategy tester for running Expert Advisors

The strategy tester opens as the bottom window of the Metatrader 4 workspace, allowing the trader to test and optimize trading systems and to keep track of current positions at the same time.

The trader can launch the service at any time through the “View” menu or via combination of shortcuts specified in the “Strategy Tester” option.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

A trader can call the service at any time through the platform’s “View” menu or using a combination of shortcut keys specified in the “Strategy Tester” options line.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

The developers tried to make this application intuitive, so a user, even barely familiar with the Metatrader 4 platform, has almost no questions, but some features are quite specific.

Setting up Advisors properties of the Metatrader 4 Strategy Tester

The EA properties are located in the right corner of the strategy tester field and control the direct setting of test modes divided into three tabs:

  • Testing
  • Input
  • Optimization

Never optimize the initial run of the Expert Advisor! Performance test of any trading system should not be started with an attempt to “adjust” the parameters of the indicators and conditions included in it.

The optimization system uses a “genetic algorithm” that can effectively improve the performance on the test. The side result of his work is parameters tailoring for a specific historical period and instrument loaded into the tester. In real trades, when faced with another form of fluctuations (volatility, laps, etc.), the robot will make a lot of losses.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

  • The “Deposit” defines the currency, the starting size of the deposit, the direction of trade (in both directions or trades of only one type) and the type of optimization that will be disabled
  • The “Input parameters” are the settings of the Expert Advisor, the tab is completely identical to the one that appears when the robot is added to the chart.

As already mentioned above, for Expert Advisor's correct operation, you should follow the settings recommended or set by default by the developer of the trading system.

In some cases, changes are possible within “presets”, special files attached to the robot. If the Expert Advisor is popular, the settings files can be found independently on the Internet.

The VR Smart Grid robot, considered for example, has similar files of custom settings, which after downloading should be placed in the Presets folder. To do this, you need to open the MQL folder in the terminal via the Data Catalog, so that you can place the file with the extension “set” in the Presets directory.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

Then, in the strategy tester, you will only have to click the “Upload” option and select desired file in the window that pops up. Often, the Tester folder is opened by default when you select a download, so use Windows navigation to find the Presets folder yourself:

Metatrader 4 tester fields description

When you open the test service, the default option “Expert Advisor” is set to the left. It automatically displays the entire list of robots in the Experts folder and the Navigator window.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

If you select the second option - the indicator, a list of files in the Indicators folder will be displayed.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

To run the Expert Advisor test, double-click on its name in the drop-down list. Next, the instrument, according to the quotes of which the effectiveness of the trading system will be checked, is selected in the same way - one click is enough to display it in the settings window.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

The “Model” function determines the accuracy and duration of testing, the “every tick” method restores historical quotes using all data of the archive, so it is the longest, the other two types do not provide an accurate estimate and are used by developers at the stage of testing “trading hypotheses” to save time while searching for ideas.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

In some cases, when the logic of the robot is “tied” to a long-term strategy, where trades are opened at the price of opening a candle (bar) at the beginning of the day, you can resort to a model with the appropriate name — will allow the trader to “rush” the Expert Advisor through the maximum time period.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

The duration and accuracy of the test is affected by the date or length of the historical segment. Some traders believe that the bigger it is the better, but empirical experience proves that:

  • It is much more important to choose a section with the most symmetrical (even) distribution of upward trend, flat and various volatility levels
  • A segment from 2000 to 10,000 candles or bars of the timeframe — the interval selected in the “Period” menu — is enough

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

As mentioned above, one of the tasks of testing is to check the “logic” of opening and closing trades, the work of money management — automatic placement of pending orders fixing losses and profit. Thanks to the visualization option, the trader can personally observe these processes in the “high-speed run” mode of trading sessions.

The “Visual mode” option offers the user to choose the inclusion and duration period of the trading demonstration.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

Setting the above settings allows you to simply press the start button of the test, leaving out the “Spread” parameter, where the default value is “Current”. This can lead to unreliable results for two reasons:

  • When testing at the weekend when the market is closed, the spread on the instruments may be implausibly overstated
  • In real trades, the spread can change, besides there will always be slippages, delays affecting the entry and closing price of the transaction

Sometimes traders input the spread cost manually, higher by one point of its real value, in order to somehow take into account the losses described above.

Launching the Expert Advisor Testing

After choosing the method of modeling the trading history and the length of visualization segment, set a fixed lot size equal to 0.1 in the EA input tab. This will help to display the dimension of the test report indicators in points, which will make the analysis of test results convenient.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

Testing starts by the “Start” button and passes automatically, displaying only the segment selected on the chart above. You can pause (1), accelerate (2), reduce or expand trades by moving the slider (3).

If the “every tick” method is selected, the candles are recreated in the tester and the price produces fluctuations, almost with reliable accuracy, which allows to display trades not at the opening and closing price, but directly “inside” the candle.

After the test is finished, new tabs are added to the service, which were not present at the tester startup stage: Journal, Graph, Results and Report.

Analysis of the Expert Advisor Test Results

Preliminary evaluation of the effectiveness of the trading algorithm is carried out:

  • Generalized, with the help of graphical analysis of the yield curve — equity
  • Mathematically, by checking the correspondence of the obtained parameters with valid theoretical values
  • Step by step — considering each trade on the chart and in the results table

The stability of the EA code is determined by the tester log.

“Testing finale” Anomaly

At the final stage of testing in the Metatrader 4 strategy tester, the service performs a “trading breakout”, i.e., forced closing of orders with an actual loss or profit. While testing medium-term, long-term strategies or Expert Advisors practicing order grids, as in the case of VR Smart Grid under consideration, the trader can see an inflated loss at the end of the test, which will be reflected in a sharp drop in the curve of profitability — equity (equity).

Results tab

The Results tab contains a detailed description of the completed or modified trade transaction, as well as pending orders and trading results.

All actions of the Expert Advisor's automatic strategy have a sequential numbering, which is contained in the first column for easy navigation when searching for work failures, as well as the time of operation, located in the second column.

Numbering of trades is contained in the fourth column “Order”. When modifying limit placed orders, it does not change, for example, the yellow marker marks the placing of the second limit order for sale, so the column contains the number 2. It is repeated in the following line: due to the change of the previous Sell order, the robot added a related stop loss order to limit losses in case of an unfavorable price movement.

The trade type is determined by the third column, the operation of the money management unit of the strategy is displayed in S/L and T/P (stop loss, and take profit) numbers. The “Price” column shows the price level of pending or executed orders on the market, “Balance” - the dynamics of the deposit changes.

In the above example of testing the VR Smart Grid Expert Advisor, the trader should pay attention to how the volume increase and the trailing stop is rearranged after the positive change in the in the direction of the open trade and check on the chart whether these operations coincide with the logic of the robot algorithm.

Graph tab

The Graph tab is divided into two fields. The first one contains two lines: balance (blue) and equity (green). The balance changes only when positions are closed, and the current funds change depending on the current values of accumulated profit or loss, which explains the mismatch of these curves. The second window, located at the bottom, displays a histogram of position size, it will be constant for a strategy using a fixed lot opened by trading signal of the robot. In this example, VR Smart Grid Expert Advisor works on a complex grid strategy using position increment, which is displayed with different height of columns.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

Report tab

Report” is the most important tab, objectively, in numbers, determining the test results. First of all, you should pay attention to the quality of trading history modeling (1), sometimes it is difficult to achieve 90curacy, so The Advisor should be tested on a demo account.

Articles, forex, advisors, indicators, strategies, scripts, training, forex educational program

Simulation errors will be displayed:

  • A stripe of red or gray
  • A specific number of candles that do not coincide with the chart on which trading is taking place
  • Percentage and green bar of correctly recreated candles or bars

The length of the tested period is indicated by the number of candles, the “working timeframe”, in the example under consideration this is an “hourly” - H1. The line below (2) contains the initial deposit and spread data configured by the user before starting testing.

Line (3) determines the benefit of the strategy in terms of profit, net and total profit, even total loss play a relative role, the following parameters are much more important:

  • Profitability
  • Mathematical expectation – arithmetic average probability calculated by the formula (Total profit - Total loss) / Number of trading positions.

Losses and profits in the strategy are posted in line (4):

  • Absolute drawdown – the maximum actually recorded loss
  • Relative drawdown – the maximum minus received from an open position

The remaining parameters - the absolute numbers of profitable and unprofitable positions are not as important as:

  • Total number of transactions – indicates whether the test length is sufficient or insufficient
  • Share of unprofitable or profitable trades

The rest of the report is a kind of “collection of records” for the largest test losses and profits, where you should pay attention to the maximum series of continuous transactions closed in the red.

Journal tab

Log is a statistical step-by-step report on the work of the Advisor. Unlike the terminal logs, it does not contain service messages (information about the robot starting, shutting down, etc.); it contains only a description of the transactions.

The log will definitely display code errors if any are found during work. If this happens, you need to contact the developer or download the Advisor elsewhere.

Saving and analyzing the test report

By right-clicking on the “Report”, “Results” and “Graph” tabs, you can save them for further analysis.< /p>

The drop-down menu provides options for copying or saving to a file, the path to which the trader chooses independently or agrees with the default option.

Copies are needed for comparison with other testing options that require different parameters or settings to be selected.

What to look for:

The main task of testing is an express check of the Expert Advisor’s profitability, therefore, on the first “Chart” tab, the trader should observe a growing equity line. At the same time, the stability of earnings is guaranteed by indirect indicators:

  • Smooth growth of the capital line, with no sharp growth or dips in the curve
  • The angle of inclination of the trend tangent is 30-45 degrees

On the “Report” tab, first of all, pay attention to the number and percentage of profitable transactions

  • The higher the number of closed transactions, the more reliable the resulting report parameters
  • The ratio of profitable trades should be at least 60% for an intraday strategy and above 70% for a medium- and long-term trading system

A large number of positively closed orders can ultimately result in a loss if the trader “forgets” about such a parameter as profitability:

  • The final ratio of profit and loss, ideally, should be higher than 2

Such a figure can be achieved by controlling the size of stop losses - orders that limit losses, in relation to automatically fixed profits, the size of which is determined by pending orders - take profits.

The table on the “Results” tab shows the total values for each positive and negative trade. Studying a random sample will help you understand the systematic nature of stop loss and take profit sizes. If the algorithm contains too high losses, a series of them can “kill the deposit.”

The “continuous losing trades” parameter will give you an idea of the possible length of a series of negative trades.

When analyzing the above results, the trader should understand that the tester’s task is an express analysis of the robot’s performance. Testing only proves the absence of code errors in the Expert Advisor and the presence of a “working” trading algorithm.

Measurement of the real profitability of the strategy is hindered by:

  • Insufficiently accurate emulation of the movement of historical quotes
  • Failure of the service to take into account the market circumstances of trading in full

Fluctuations in exchange rates or other Forex market instruments are ensured by a continuous flow of client transactions, so-called ticks. It is this information that s stored on the servers of the broker to which the installed Metatrader trading platform is “linked”. Despite the universality of the program, each broker independently handles the filling, i.e. collecting your own version of quotes.

When the tester is launched, each candle (or bar) is emulated - filled with ticks; these are millions of transactions that cannot always be accurately repeated in full. The program will automatically report this if the trader chooses this testing option.

Even with 99curacy in reconstructing candles (or bars), the tester will not be able to take into account:

  • Fluctuations in the spread, which is never constant, the broker always reserves the right to expand this parameter when news comes out
  • Various technical problems - failures in quotes broadcast, loss of archived data
  • Slippage when executing trades

Based on the above, it becomes clear that despite the advertising of the tester as an ideal process for determining the profitability of a strategy, the result of real trading will be very different from the obtained figures. Use the obtained profit data to set test parameters for trading on a demo account as close as possible to real trading. Only they can accurately determine the real profitability or unprofitability of the Advisor.

Testing the advisor on a demo account

Running the advisor on a demo account provides the greatest reliability of testing results, however, this method requires a significant investment of time. In addition, when testing, it is advisable to use a VPS server.

What is a VPS server?

VPS server is a service which appeared among hosting providers with the development of automated trading. The company provides traders with remote access to the Metatrader platform installed on powerful servers in data centers.

The operation of the Advisor's algorithm depends on the presence of an uninterrupted Internet connection, with the help of which the robot “keeps in touch” and manages pending and triggered orders, according to the underlying logic of the trading strategy.

A broken connection or shutdown of the Metatrader 4 terminal leads to a failure; the user will have to independently close open ones and cancel pending transactions after it is restarted. If at this moment the trader is not near the computer, the transactions will remain “hanging” on the broker’s server and can bring unlimited losses.


VPS server is used to allow trading to take place automatically without the risk of any failures. Operational stability is guaranteed by:

  • The company is the owner of the data center, for which this is the point of business
  • Location of the broker and trader servers in the same place

The latter fact gives an additional advantage to the user of the VPS server , increasing the speed of order execution due to a smaller ping size or, one might say, greater speed, changes in quotes.

Hosting provides full technical and consulting support and assistance in setting up a VPS server, so the service can be used with any level of knowledge.

How to choose the right demo account type and amount to test your strategy

Forex brokers provide traders with a choice of different account types designed to optimize the cost of commission payments. These conditions are completely duplicated on demo accounts.

Testing the Advisor on a demo account should not be any different from real trading, therefore the type and deposit amount must match the real Forex trading account , on which it is planned to use the advisor. This issue must be closed by the trader independently before the first launch of the robot, based on the trading strategy algorithm, or it can be taken into account in the instructions/recommendations attached to the Advisor.

Sometimes they pursue advertising purposes for affiliate earnings - the developers even recommend a specific broker, so let’s give a brief overview of the main types of accounts.

In the Forex market, brokers offer 4 different options for paying commissions in the form of:

  • Fixed spread
  • Floating spread, sometimes called “zero” for advertising purposes, which is why this word is often indicated with an “asterisk”
  • Accounts with cent deposits
  • “Islamic” or “swap-free” accounts

Swap is the daily accrual/withdrawal of commission for using leverage. The parameter is calculated as the difference in rates between the central banks of the countries that own both currencies in the pair. A broker, like any bank, charges interest on a loan on the currency sold, while at the same time accruing plus interest on the purchased currency.

For example, selling the EUR/USD pair looks like buying dollars for sold euros. The European Central Bank maintains an almost zero rate, therefore the interest for using the euro will be zero, and for the amount of US dollars purchased, a commission will be charged at the rate of 2.5% per annum for each day of holding. This is a fairly low income or loss, so “Islamic or “swap-free” accounts do not play a significant role in choosing the demo mode of testing the Expert Advisor.

Cent account is opened by traderswho trade for an investment amount not exceeding $100, which the Metatrader 4 functionality will present as 10,000 cents. Such a “cent transformation” of the deposit is necessary when trading Advisors using the grid strategy (placing multiple orders against the trend) or Martingale (increasing the size of the order after each unprofitable transaction). To launch it on any standard account you will need a deposit of $1000 or more; in the “cent version” $100 is enough.

Accounts with a fixed spread are chosen by traders who launch robots with an average frequency of once, twice a day or more. The average profit per transaction makes the cost of the commission negligible, and the calculation of expenses is simple, just multiply the spread by the number of transactions

Intraday, short-term or scalping strategieswith a large number of trades in one session use floating spread accounts. They come under many acronyms: ECN, NDD, STP or DMA. The name determines the method of execution of the transaction and the mechanism for forming the spread, the details of which are described in the accompanying specifications for the account.

If a trader does not understand dealing desks, order books, and the rules for market execution of orders, he should not use a scalper robot, which, without knowledge of the intricacies of intraday trading, will wipe out the deposit in one day.

The size of the amount is determined by the results of testing in the strategy tester. The first part of the description of this process describes the tactics for launching an Expert Advisor with a fixed size of 0.01 lots. This choice allows you to equate the maximum drawdown parameter from the “Report” tab to the exchange rate points of the currency pair.

In the VR Smart Grid testing example, the result was 155.38, which means that the robot must “withstand” a loss:

  • At $15.54 when trading 0.01 lots – the margin for which is $10
  • At $155.38 when trading 0.10 lots with a margin requirement of $100

How to correctly take into account losses from a mathematically sound point of view, a trader can read in the books of Ralph Vince, but an easier way to determine the size of the deposit is to multiply the maximum drawdown figure by the maximum series of losing trades and then by a factor of 3.

In the example under consideration, the following deposit amount will be obtained:

15.4 x for the maximum series of losses in a row (4) x 3 = 186.45

This means that when testing the VR Smart Grid Advisor, the deposit amount on the demo account should be:

  • For trading lot 0.01 - $186.45
  • For trading 1 lot - $1864.56

The coefficient was chosen empirically and means a triple maximum margin, so the higher it is, the more stable the strategy.

How to choose the number of currency pairs to test the Expert Advisor on a demo account?

Trading algorithms are often written for specific Forex instruments; this fact is especially noted in the settings or recommendations for the Advisor. If the strategy is universal, the user testing the robot on a demo account should start from:

  • The estimated investment amount determined by the size of the deposit according to the above calculation method
  • Trade frequencies in the strategy
  • Testing objectives

The Metatrader 4 trading platform allows you to run as many copies of the Expert Advisor as the number of instruments the broker offers. A large number of instruments, in theory, diversifies the strategy, compensating for losses on one pair with profits from another.

In practice, movements in the Forex market are subject to the laws of correlation - the fall and growth of currency pairs coincide, especially during moments of strong movements caused by global macroeconomic events. Therefore, choosing a large number of instruments only increases the load on the deposit instead of the expected diversification.

Before increasing the number of currency pairs, the trader will have to return to the strategy tester and determine the size of the maximum loss for each of them in order to take it into account when testing the Advisor on a demo account. The trader will have to increase the investment amount or decrease the lot size, allocating a trading deposit separately for each currency pair, calculating the reserve using the formula described above.

An exception may be the situation of launching the Advisor on medium- and long-term strategies, provided that a different class of instruments is selected: currency pairs, indices, commodities and commodities. If a run on the strategy tester showed on the “Visualizations” or “Results” tab and the frequency (mismatch) of transactions on the selected instruments, the trader can calculate one deposit for all instruments by selecting the average drawdown size and using a coefficient of 5 ( instead of 3) to calculate the deposit amount.

If the user is faced with the task of finding the most profitable currency pair for the Advisor during testing on a demo account, then he can launch many instruments, using a larger deposit than planned for real trading. However, this process will lengthen the tests on the demo account - a second stage will be required, where only the selected pair will be tested separately, already reduced to the planned future deposit.

How to determine the timeframe - time trading period?

The size of the timeframe—the time trading period represented on the chart by a candle or bar—determines the “accuracy” of the Expert Advisor’s trades, so this parameter is initially set in the default settings or reflected in the recommendations.

Some strategies implemented in robots are scalable, i.e., the trading algorithm can work on different time periods. Before testing the Advisor in Metatrader 4, the user must determine what period he will use in real trading and set a similar one in the demo account settings.

The size of time frames is standard, defined by a series of minutes: 1.5, 15, 30; hours: 1, 4, and higher intervals - day, week, month.

The choice of lower, minute periods implies a higher frequency of transactions, often used to “accelerate” the deposit. If a trader does not have large funds and sets the goal of “quick earnings” in the market, he will choose minute intervals. This will mean intraday trading, in which the following restrictions must be used:

  • Trading time limit to avoid inactive trading segments during the day
  • ban on postponing positions “through the night” and weekends

The choice of an hourly timframe is a medium -term strategy, daytime - long -term, candles are chosen less often in traders per week or a month.

Fracture of graphs in the Forex market have a fractal structure, which means a semblance of cyclicity and shape, inside the hour, with changes in the course inside the day or week. This knowledge allows the trader to intentionally choose a smaller period to speed up the adviser test on the demo account. Profitability on small timeframes means that the strategy will definitely “pass” at higher periods.

How to change and apply the adviser settings?

Changing the time periods, the Tramprames trader must take into account the interconnectedness of their size with the settings of the adviser. Inside the robot, a trading system can be programmed, whose periods are synchronized with calendar data, the sizes of automatically constructed levels are “tied” to certain percentage changes in the exchange rate course, etc.

In order for the strategy to work effectively on the user settings of timeframes other than the developer installed, the trader must understand the mechanism for setting transactions, understand the composition of indicators or other principles for the formation of trading signals by the robot. This will help to correctly choose and synchronize the adviser parameters for any changes in one or more settings.

First of all, on the demo account “driven away” options for the developer, there may be several, then they are reflected in preset files.

The ability to independently change the parameters is limited by the “ input parameters ” tab. Codes - the creators of the robot, take into this window only those settings that the trader can change without the risk of “ to destroy ” the algorithm performance.

If the trader is not familiar with the implemented trade strategy, he can find her analogues in specialized forums. With convincing evidence about the performance of certain parameters that are part of the indicator adviser, they can be changed in the robot settings.

How to attach an adviser to the selected tools?

The adviser is added to the instrument schedule with a simple “drag” from the navigator window. The connection will automatically open the adviser settings. Most of them are accepted by the default trader or change according to the instructions attached to the robot. The setting of the strategy “for yourself” should be carried out using only confirmed their performance in the tester, as well as on demonstration and real auction in Metatrader 4 ideas of the trading system.

After installing an adviser on the schedule, the trader should pay attention to the smiley that arose in the upper right corner-the smile means successful launch and the start of the robot. Sad Smiley indicates problems with settings.

Metatrader 4 platform for working with advisers requires the inclusion of additional options. They are located in the service menu - the “ settings ” item and are installed once, then they work for any new robot.

in the window that opens, find the "Advisers" tab and mark (turn on) all points by clicking on them with the left mouse key.

Click the OK key and go to the setting of " properties " of the robot, they are available by the right key key on the graphic, in the drop-down menu of the " advisers. ".

so that the smiley begins to smile, allow the adviser to trade by initializing the option with the corresponding name and by pressing OK.

the remaining points of this settings window are used "by default", unless otherwise provided by instructions that are included with the robot. In this case, the trader can connect libraries, limit the trading of transactions in one direction, etc.

How to choose the right period of testing an adviser?

The testing process on the demonstration account should give the trader an understanding of what performance the robot will show in any “states” of the Forex currency market, especially in “vulnerable” areas for the trading system. These include:

  • Flat - for trend systems
  • News - for the trading strategy in the range
  • impulses - when trading on a "breakdown" level

The test data, which includes only continuous growth or fall, for trend strategies are unpresentable, since such a robot carries losses on Flatte . In this case, the trader must initially visually determine the average length of this type of vibration using a bellinger, using historical quotes, and wait for a similar length of the period on demo accounts.

Trade in the range is mainly held at the Asian session, which participates the smallest number of forex traders, which guarantees the absence of trends. The situation changes dramatically when important unprofitable news in China or Japan, fluctuations in other publications can be avoided, predicting them in advance thanks to the information from the economic calendar.

In this case, the number of news cannot be predicted accurately, so the trader should rely on an empirically calculated average result. The results of the trading during the exit of important economic indicators, which the trader avoids at real auction, will help to evaluate losses from unpredictable movements. The time of their publication is known in advance, and the number of sessions for testing an adviser should be equal to the average result of the appearance of “unexpected” news.

Impulse trade is the setting of deferred orders at important price levels in anticipation of strong changes in the course in a short period. They can be “provoked” by the release of news or predicted by technical analysis methods. During the testing of an adviser, inside which the logic of pulsed trade is implemented, the trader needs to wait for a symmetrical number of transactions for the purchase and sale (breakdown of the “down and up” level).

The advantages and disadvantages of testing the adviser on the Forex demo account

Forex demonstration account is a 99.9% guarantee of creating conditions similar to real trade, which allows you to rely on the result shown by the adviser. The trader chooses the form of the account, deposit size, “working” timeframe and can predict the size of the profit and loss of future investments in the selected robot.

The only minus of this type of testing is the duration, the adviser must pass the stages of trade, and the trader to wait for the trend, a jump in the news on the news and other Forex market strategies on which the size of the greatest possible loss depends, as well as to reject the interval equal to these periods. This helps to understand the speed of restoration of the deposit after a series of negative transactions and correctly determine the size of the trading lot and the “reserve” of investments in order to avoid ruin.


Testing is an obligatory part of the algorithm for accepting any new trading system, especially important in the intention to automate trade. In the process of analysis, the trader will receive a visual idea of the mechanism of opening and closing positions, theoretical scale of loss, a share of profitable transactions.

At the same time, the tester is not a reliable indicator of the effectiveness of an adviser for a number of reasons marked above. Reliable data will give real auction, which at the first stage must be replaced with a period of work of the robot in a demonstration account in order to prevent deposit loss.

The strategy checked should be put on bidding using Metatrader installed on vps service for reliable round -the -clock support of the Internet and protection against technical failures in energy networks or on a broker servers.


To write a comment, log in Enter


Password recovery Registration

Password recovery Registration
Password request

If you forgot your password, enter your e-mail. The control line for changing the password will be sent to you by e-mail.

A link has been sent to your email address to confirm the E-mail address. To complete the registration, follow this link.

If you have not received an email to your email, check the Spam folder. If there is no letter there either, then contact us.

Registration completed successfully!

You have successfully logged in to the site!

We use both our own cookies and third-party cookies for the purpose of analysis, as well as to display ads based on your preferences, in accordance with your browsing habits and your profile. For more information, please see our Privacy Policy.
Even more in the Telegram community Send us a message