Forex algorithmic trading
Many years ago, the forex market was only accessible to banks and institutional clients who placed majority of their trades over the phone. With the advent of modern technology, the market became widely accessible to global clients who placed their orders via software trading platforms. These platforms offer real-time pricing, multiple order types, charting packages, etc. The more sophisticated platforms such as MT4 offer algorithmic trading.
An algorithm is a set of clearly defined rules written for the computer to carry out a specific task. So, forex algorithmic trading allows the computer to scan the markets, find trading opportunities and execute trades on behalf of a forex trader. First of all, the trader codes his trading strategy or algorithm for the computer.
A forex robot is a software or program that uses technical analysis principles to analyze the price charts, then open and close trade positions automatically in line with its program. So, the trader can save time or even sleep while the robot trades on his behalf. Forex robots are usually installed on compatible trading platforms. Some of the popular trading platforms that support algorithmic trading are MT4, MT5, cTrader, NinjaTrader, JForex, etc.
Expert advisors (EAs)
These are forex trading robots designed for the MT4 or MT5 trading platforms. When installed on the MetaTrader platforms, an EA can automatically detect a trading opportunity, and enter and exit the market without the trader’s interference. Since MT4 and MT5 are not compatible, EAs built for MT4 will not work on MT5, and EAs built for MT5 will not work on MT4.
You can code and compile your EA on the MQL MetaEditor using the MQL4 programming language. If you want to run your EA on the MT5, then, you must use the MQL5 programming language. The MQL is based on the C++ programming language. It is used for coding EAs, indicators, and other trading tools designed for the MetaTrader platforms.
Another option is to buy your EA from the MetaTrader market which comes with the trading platforms. Some EAs are free while some are for renting or outright purchase.
Installing an EA on MT4
If you have downloaded an EA, you have to place it in the appropriate folder before it can appear on the MetaTrader platform. Copy the EA file and place it in the ‘Experts’ folder found within the MetaTrader folder in the C drive or the programs folder where your MT4 installation resides.
Follow the steps below to install an EA into your MT4 platform:
- Launch the desktop version of the MT4 on your pc.
- Login to your account
- On the menu bar, click view> navigator. The navigator window opens.
- Click on the + sign beside Expert advisors.
- Locate your EA and drag it to the charts on the platform.
- A menu pops up for you to set the parameters of the EA.
- Click OK.
The EA appears on the chart and starts scanning the market.
Virtual Private Server (VPS)
VPS is a virtual computer made available to forex traders as a service. Traders who use EAs often require a VPS. Most VPS services charge a monthly subscription based on the speed and complexity of the server. Some brokers offer discounted VPS services to their clients in partnership with VPS providers. Traders will have to install their MT4 trading platform on the VPS machine. VPS has the following advantages:
- It gives uninterrupted access to the trading servers. Some VPS providers offer uptime reliability of up to 99%.
- Speed: It makes EAs faster in the execution of trades and analyses.
- Cyber security: VPS providers use the latest technology to secure the machines against hackers and malicious softwares.
With a VPS installed, if you are in a location where internet access is limited or erratic, you have nothing to worry about. In case of power failure, or your computer is faulty, your EA will be running uninterrupted from the VPS machine.
How to install a VPS obtained from a service provider
- Order a VPS subscription service. You will receive an email containing an IP address, your username, and password.
- On your computer, click on start>accessories>remote desktop.
- Input the details received from the VPS vendor, that is; IP address, username, and password. Click ‘connect’.
- Your virtual computer loads and presents an empty desktop. You can visit your broker’s website and download the MT4 platform.
- Install the MT4 and log in to your account.
- Install your EA. If it is on your local PC, you can find it by clicking on the ‘local resources’ tab on the ‘Remote desktop connection’ dialogue box. You can choose the drives to share with the VPS.
- After installation of the EA, you can attach it to any chart.
To rent a VPS directly on the MT4 platform
If you have no VPS provider, you can still get VPS service on the MT4 platform. Just follow the steps below:
- From the Navigator window, right-click on ‘account’ to display a shortcut menu
- Select ‘Register a virtual server’.
- Choose a virtual server and click ‘next’.
- Log into your MetaTrader community account with your email and password.
- Follow the prompts of the wizard to complete your migration to the VPS.
Upon successful migration, you will receive a message on the platform and all trading will be migrated to the VPS.
Pros and cons of forex algorithmic trading
- It saves valuable time. Some traders spend hours analyzing the charts but forex robots accurately scan and analyze the charts 24 hours without getting tired. The trader can then focus on other things.
- Forex robots are precise and very fast when compared to human traders. It can analyze all variables simultaneously and make intelligent decisions within seconds.
- Robots are emotionless irrespective of constant losses or wins; an EA continues to execute trades according to its algorithm.
- Most forex robots deliver good results in the short term but in the long run, they blow the trader’s account. So, constant monitoring and algorithm modification are often required. EA sellers always upgrade their softwares to reflect new market sentiments.
- Generally, they do not incorporate fundamental analysis. For example, a sudden release by the ‘Bank of England’ may affect GBP but your EA will not read the news and will still follow its algorithm. This may lead to big losses if you are trading a pair that has GBP.
- Not every trading strategy can be automated. Some pro traders develop complex trading systems that rely on a combination of different strategies and so cannot be automated using robots.
- Forex robot scams are rampant. Always research a dealer before you buy their EAs or robots.
Algorithmic trading is the use of software robots to trade financial markets such as forex, stocks Cryptocurrencies, etc. Forex robots are computer programs that can analyze the charts and automatically execute trades according to the strategy already programmed in its algorithm. Trading platforms like cTrader, NinjaTrader, MT4, and MT5 support algorithmic trading.
EAs are trading robots built for the MetaTrader platforms. They can be scripted with the MQL programming codes or acquired from the MetaTrader Market. Forex VPS is essential to all EA users because it ensures security and reliable connectivity to the brokers’ servers. You can buy or rent VPS from some brokers, online vendors, or directly from the MetaTrader platforms.
Automated trading is fast becoming more and more popular because of its great advantages. It is faster, more accurate, works 24/7, and has no emotions whatsoever. Unfortunately, it needs regular updates as none lasts forever. Also, scammers have devised different strategies to scam robot users.