Trading robots or bots are tools that help to automate the trading process. Some bots identify signals and send alerts, while other sophisticated ones can open trades and set the necessary steps. 

Many traders without coding experience buy custom-made bots from leading marketplaces like MQL5 and MQL4. Those with trading experience can build their own bots within a few weeks. This article will look at some of the top mistakes to avoid when you are building trading robots.

How trading bots work

Trading bots are built to automate manual activities when you are trading. For example, assume that you are a day trader who uses the 25-day and 15-day Moving Average crossovers to find entry setups. You can spend the entire trading session waiting until the conditions for the entry setup are met.

Alternatively, you can build a trading bot that combines the two Moving Averages. The bot will scan your predetermined currency pairs and open trades when the two averages cross over. Another type of bot will send you an alert when your preferred currency pairs make the crossover. With the alert, you can analyze and determine whether the pair is a buy or sell.

Therefore, you need some experience in both trading and software development to build a high-quality trading robot. Python, MQL 5, MQL 4, and C++ are the top programming languages you need to know.

Creating a bot using MT5. The screenshot shows the templates section of the MT5.

Still, if you don’t have this experience, you can buy custom-made trading bots directly from developers or through a marketplace. Alternatively, you can use templates provided in platforms like MT5 and MT4. The illustration above shows the templates section of the MT5.

Not backtesting

You are backtesting the bot when you take the bot through evaluations to see how it will perform in the real trading environment. By taking the bot through a rigorous testing process, you will identify whether it works and the expected returns. We can use the analogy of an auto company that comes up with a brand new car brand. Before the company starts sales, it puts the vehicle in a series of tests to ensure that the car meets the standards. 

Similarly, when you build a robot, using it directly in a live account without backtesting is a mistake. Fortunately, most trading platforms like TradingView and MT5 have a backtesting feature. To access it on the MT5, you just need to go to view and then select strategy tester. You can also use the shortcut of ctrl+r. After that, you should select the bot you have built and then run a test.

Backtest results example

The chart above shows the results of a simple backtest. As you can see, the bot opened 165 trades and made a net loss of $415. 

Backtesting wrongly

While backtesting is always recommended, many traders make the mistake of backtesting the wrong way. Ideally, you need to ensure that you are testing the real data. For example, it is wrong to do a backtest on a daily chart if your trading strategy involves trading on a 5-minute chart. 

Similarly, you should avoid testing assets that you don’t trade. If your focus is on major currency pairs like the EUR/USD and GBP/USD pairs, you should not base the outcome of the bot on a commodity like crude oil and copper. 

Therefore, there are several things that you should look at when doing the backtest.

  • Period of backtesting – You can select the period in which you will apply the backtest. We recommend that you start from a long period and narrow it to the nearest period. In this, you should test the bot in a 10-year period down to the past month. 
  • Chart timeframes – You should focus on the timeframes that you normally trade. It would not make sense to focus the bot on a daily chart if you normally specialize on the four-hour chart. Still, during the testing, you should check out multiple timeframes and see the results.
  • Symbol – You should test the robot on the symbols that you normally trade. 
  • Forward – You should select whether you want to forward-test your trading robot. You should add a forward date that is not too far.

Backtesting setup in MT5

The chart above shows the settings page of backtesting.

Not adding risk management setups

As you possibly know, risk management is an important concept in day trading. It refers to the process of reducing risks while maximizing your returns. Also, no trading robot is 100% perfect. Therefore, if you are building a bot that will open and close trades automatically, it is wrong not to include risk management tools. In my experience with bots, some of the top risk management mistakes I have seen are:

  • Not adding stops – It is possible to add a stop-loss or a trailing stop-loss when building trading bots. A stop-loss will automatically stop trades when a certain loss threshold is reached. A trailing stop, on the other hand, will move with the trade and stop it when triggered. You should also add a take-profit, which will stop the trade when the currency pair reaches the target.
  • Lot sizes – Another mistake is not setting the right lot sizes in the trading bot. We recommend that you start with small lot sizes and then increase them as you see the success of the bot.
  • Leverage – After seeing strong backtest results, many traders use relatively high leverage. While this leverage can make you more money, it also exposes you to more losses when things go south. Therefore, you should add the right leverage when building the robot.

Summary

There are other popular mistakes that we see when people are building and using bots. For example, some traders don’t monitor their trades when the robot is at work. Other traders use the wrong volume when doing the backtesting. For example, they backtest with $10,000 when they start trading with $1,000. You should backtest with the same amount that you will start trading live with. 

Leave a Reply

  +  44  =  53