Watch how to download trading robots for free
Find us on Twitter!
Join our fan page
Access the CodeBase from your MetaTrader 5 terminal
Couldn't find the right code? Order it in the Freelance section
How to Write an Expert Advisor or an Indicator

Top MQL4 and MQL5 source codes based on user ratings - 50

Submit your code

Quantile bands - new version.

The "Nevalyashka" Expert Advisor.

The EA uses two Moving Averages, one MACD and one CCI. OnTradeTransaction is used to receive position opening time.

A script for placing a BuyLimit order

A script for placing a SellStop order

Hedge The Hedge Trader EA.

A channel based on peaks and troughs of the ZigZag indicator.

The XMA_Divergence indicator with the possibility to change the indicator timeframe from input parameters.

The indicator shows a text block with the values ​​of the user defined RVI oscillator period for each timeframe.

Two identical trading systems based on the change in the color of XFatlXSatlCloud for long and short trades, which can be configured in different ways in one Expert Advisor.

A trading system based on ColorJFatl_Digit indicator signals with the possibility to set a fixed position holding time.

Chandes Quick Stick (Qstick)

The Volume Rate of Change indicator (VROC) measures the rate of change in volume over the past "n" sessions. In other words, the VROC measures the current volume by comparing it to the volume "n" periods or sessions ago.

Smoothed Rate of Change (Smoothed-RoC) is a refinement of Rate of Change (RoC) indicator that was developed by Fred G Schutzman. It differs from the RoC in that it based on Exponential Moving Averages (EMAs) rather than on price closes. Like the RoC, Smoothed RoC is a leading Momentum indicator that can be used to determine the strength of a trend by determining if the trend is accelerating or decelerating. The Smoothed RoC does this by comparing the current EMA to value that the EMA was a specified periods ago. The use of EMAs rather than the price close eliminates the erratic tendencies of the RoC.

A simple oscillator, which is based on the values of the iStochastic, iRSI and iMomentum indicators and is implemented as a two-colored histogram.

Example of functions MathCeil, MathRound and MathFloor.

APR

Average Period Range - an indicator of the average daily range.

Elastic Volume Weighted MA

Least Square Moving Average - a moving average calculated by the least squares method.

An indicator of StopLoss levels.

Impulse Indicator - Count of Points Passed.

The KWAN_CCC indicator with the possibility to change the indicator timeframe in input parameters.

Sherman and Marian McClellan Oscillator.

Two channels by the High and Low of MA.

Indicator Trend Confirmation Index

Trend-following trading system Exp_ColorX2MA_X2 based on the signals of two indicators ColorX2MA

A utility for closing (reducing the right side of the length) the rectangles.

IMI

Indicator Intraday Momentum Index.

NV

NV (Natenberg's Volatility) - Sheldon Natenberg's historical volatility indicator.

VFO

The VFO (Volume Flow Oscillator) values above zero are bullish and indicate accumulating, while those below zero indicate distributing. Divergences between the price and the indicator values may indicate a forthcoming change in the trend.

CI

Indicator CI (Congestion Identifier). It displays within how many bars before the current one the price was within the channel formed by the Close price of the current bar +/- Delta in points. It also displays the counter value threshold level and the marks, in which the counter is above or below that level.

Indicator Ang_Zad_C_Hist_Candle with the timeframe selection option available in the input parameters

An Expert Advisor for closing all positions, in case of the total losses on those positions exceeded the Stop Loss level fixed in inputs, or where it is necessary to close all positions beyond the time interval fixed in the settings.

An indicator that colors candlesticks going beyond channel Ozymandias.

WVF Stochastic indicator

ALWMA moving average

The Henderson Filters are derived by minimizing the sum of squares of the third difference of the moving average series. Henderson's criteria ensures that when these filters are applied to third degree polynomials, the resulting smoothed output will fit exactly on these parabolas. The Henderson Filters are suitable for smoothing economic time series as they allow the cycles typical of the trend to pass through unchanged. They also have the property that they will eliminate almost all the irregular variations that are of very short frequencies of six months or less.

Trend Trigger Factor indicator ported to MQL5 from wrongly coded version for MetaTrader 4.

One of the variations of the "Avalanche" strategy. Martingale is used.

GD

The Generalized DEMA moving average

1...434445464748495051525354555657...188