Download MetaTrader 5

MQL4 Programming Articles

Here you can find articles on MQL4 - programming language of trading strategies. Most of them are written by traders and active members of MQL5.community. For more convenience, all articles are grouped into several categories - Experts, Indicators, Trading Systems, etc.

Watch out for new articles and discuss them on the Forum!

latest | best

Reading RSS News Feeds by Means of MQL4

This article deals with an example of reading RSS markup by means of MQL4 using the functions for HTML tags analysis. We will try to make a work piece which can then be turned into a news indicator or...

LibMatrix: Library of Matrix Algebra (Part One)

The author familiarizes the readers with a simple library of matrix algebra and provides descriptions and peculiarities of the main functions.

Mechanical Trading System "Chuvashov's Triangle"

Let me offer you an overview and the program code of the mechanical trading system based on ideas of Stanislav Chuvashov. Triangle's construction is based on the intersection of two trend lines built...

Three Aspects of Manual Trading Automation. Part 1: Trading

This article is the first in a series of articles on manual trading automation in the МetaТrader 4 trading platform. Each of the articles will be devoted to one of the following aspects: automation of...

The Random Sandbox

The article includes an interactive "sandbox" as an Excel file which simulates randomized Expert Advisor backtest data. Readers can use this to help explore and more deeply understand the EA...

MetaTrader 4 Expert Advisor exchanges information with the outside world

A simple, universal and reliable solution of information exchange between МetaТrader 4 Expert Advisor and the outside world. Suppliers and consumers of the information can be located on different...

MetaTrader 4 on Linux

Linux is a Unix-like computer operating system assembled under the model of free and open source software development and distribution. Many home PC users prefer it to MS Windows series. Linux systems...

An Insight Into Accumulation/Distribution And Where It Can Get You

The Accumulation/Distribution (A/D) Indicator has one interesting feature - a breakout of the trend line plotted in this indicator chart suggests, with a certain degree of probability, a forthcoming...

MetaTrader 4 on Mac OS

Apple products have become very popular. MetaQuotes Software Corp. attentively follows the progress of the IT industry and has already released the special mobile applications for iOS-based devices -...

The Golden Rule of Traders

In order to make profits based on high expectations, we must understand three basic principles of good trading: 1) know your risk when entering the market; 2) cut your losses early and allow your...

Trader's Kit: Drag Trade Library

The article describes Drag Trade Library that provides functionality for visual trading. The library can easily be integrated into virtually any Expert Advisor. Your Expert Advisor can be transformed...

Synthetic Bars - A New Dimension to Displaying Graphical Information on Prices

The main drawback of traditional methods for displaying price information using bars and Japanese candlesticks is that they are bound to the time period. It was perhaps optimal at the time when these...

Mechanical Trading System "Chuvashov's Fork"

This article draws your attention to the brief review of the method and program code of the mechanical trading system based on the technique proposed by Stanislav Chuvashov. The market analysis...

Econometrics EURUSD One-Step-Ahead Forecast

The article focuses on one-step-ahead forecasting for EURUSD using EViews software and a further evaluation of forecasting results using the programs in EViews. The forecast involves regression models...

Fractal Analysis of Joint Currency Movements

How independent are currency quotes? Are their movements coordinated or does the movement of one currency suggest nothing of the movement of another? The article describes an effort to tackle this...

On Methods of Technical Analysis and Market Forecasting

The article demonstrates the capabilities and potential of a well-known mathematical method coupled with visual thinking and an "out of the box" market outlook. On the one hand, it serves to attract...

Testing (Optimization) Technique and Some Criteria for Selection of the Expert Advisor Parameters

There is no trouble finding the Holy Grail of testing, it is however much more difficult to get rid of it. This article addresses the selection of the Expert Advisor operating parameters with...

Enhancing the Quality of the Code with the Help of Unit Test

Even simple programs may often have errors that seem to be unbelievable. "How could I create that?" is our first thought when such an error is revealed. "How can I avoid that?" is the second question...

Protect Yourselves, Developers!

Protection of intellectual property is still a big problem. This article describes the basic principles of MQL4-programs protection. Using these principles you can ensure that results of your...

Contest of Expert Advisors inside an Expert Advisor

Using virtual trading, you can create an adaptive Expert Advisor, which will turn on and off trades at the real market. Combine several strategies in a single Expert Advisor! Your multisystem Expert...

Research of Statistical Recurrences of Candle Directions

Is it possible to predict the behavior of the market for a short upcoming interval of time, based on the recurring tendencies of candle directions, at specific times throughout the day? That is, If...

The Magic of Filtration

Most of the automated trading systems developers use some form of trading signals filtration. In this article, we explore the creation and implementation of bandpass and discrete filters for Expert...

Easy Stock Market Trading with MetaTrader

This article raises the issues of automated trading on the stock market. Examples of MetaTrader 4 and QUIK integration are provided for your information. In addition to that, you can familiarize...

Checking the Myth: The Whole Day Trading Depends on How the Asian Session Is Traded

In this article we will check the well-known statement that "The whole day trading depends on how the Asian session is traded".

Meta COT Project - New Horizons for CFTC Report Analysis in MetaTrader 4

The article is about the use of CFTC report data (Open Interest) in MetaTrader. The article describes the proposed META COT project in details, shows how to load and process the necessary information....

FANN2MQL Neural Network Tutorial

This article has been made to show you how to use neural networks, via FANN2MQL, using an easy example: teaching a simple pattern to the neuralnetwork, and testing it to see if it can recognize...

Trader's Kit: Decorating Indicators

In this article you will find main tasks when decorating indicators, their solution and automation.

Working with Doubles in MQL4

In this note we will consider a typical programming errors, that occurs while working with double numbers in MQL4 programs.

Interaction between MеtaTrader 4 and MATLAB Engine (Virtual MATLAB Machine)

The article contains considerations regarding creation of a DLL library - wrapper that will enable the interaction of MetaTrader 4 and the MATLAB mathematical desktop package. It describes "pitfalls"...

Superposition and Interference of Financial Securities

The more factors influence the behavior of a currency pair, the more difficult it is to evaluate its behavior and make up future forecasts. Therefore, if we managed to extract components of a currency...

On the Long Way to Be a Successful Trader - The Two Very First Steps

The main point of this article is to show a practical way to implement an effective MM. This can be achieved only by using a certain kind of strategies that we need to identify and describe first. In...

Using Neural Networks In MetaTrader

This article shows you how to easily use Neural Networks in your MQL4 code taking advantage of best freely available artificial neural network library (FANN) employing multiple neural networks in your...

Alert and Comment for External Indicators

In practical work a trader can face the following situation: it is necessary to get "alert" or a text message on a display (in a chart window) indicating about an appeared signal of an indicator. The...

Channels. Advanced Models. Wolfe Waves

The article describes rules of marking patterns of Wolfe Waves. You will find here details of constructing and rules of accurate marking, which help to find correct formations of waves quickly and...

Effective Averaging Algorithms with Minimal Lag: Use in Indicators and Expert Advisors

The article describes custom averaging functions of higher quality developed by the author: JJMASeries(), JurXSeries(), JLiteSeries(), ParMASeries(), LRMASeries(), T3Series() and MASeries(). The...

Recipes for Neuronets

The article is intended for beginners in baking "multi-layered" cakes.

Fallacies, Part 2. Statistics Is a Pseudo-Science, or a Chronicle of Nosediving Bread And Butter

Numerous attempts to apply statistical methods to the objective reality, i.e. to financial series, crash when met with the nonstationarity of processes, "fat tails" of accompanying probability...

Program Folder of MetaTrader 4 Client Terminal

The article describes the contents of the program folder of MetaTrader 4 Client Terminal. The article will be useful for those who have already started to grasp into the details of the client terminal...

Visual Testing of the Profitability of Indicators and Alerts

What indicator of trading alerts or just the methods of their calculating to use is usually decided when testing EAs using these alerts. However, it is not always possible/necessary/reasonable to...

To Sleep, or Not to Sleep?

An alternative use of the Sleep() function in the realization of pauses between EA's actions is proposed. The approach under consideration allows a smart use of machine time.

123456