Sample pine script stochastic divergence converted to MQL5 – indicator MetaTrader 5

Sample pine script stochastic divergence converted to MQL5 - indicator for MetaTrader 5
The purpose of this code is to convey an idea to people seeking simple and functional approach to converting pine script to MQL5. Here is the pine script code: //@version=5 indicator(title=’sample stochastic divergence’, overlay=true) stoch_len = input.int(title=’stoch_len’, defval=5) f_top_fractal(_src) =>     _src[4] < _src[2] and _src[3] < _src[2] and _src[2] > _src[1] and        _src[2] > … Read more

Logging V2 for both MQL4 and MQL5 – library MetaTrader 5

Logging V2 for both MQL4 and MQL5 - library for MetaTrader 5
CDebugLogger Class V2: A Comprehensive Logging Utility for MQL4/5 The CDebugLogger class is a powerful and flexible logging utility specifically designed for MQL4/5 environments. It is an essential tool for developers who need to monitor, debug, and track the behavior of their applications with precision. In this new version of the CDebugLogger class, I have … Read more

Best Logging Class for both MQL4 and MQL5 – library MetaTrader 5

Best Logging Class for both MQL4 and MQL5 - library for MetaTrader 5
CDebugLogger Class: A Comprehensive Logging Utility for MQL4/5 The CDebugLogger class is a powerful and flexible logging utility specifically designed for MQL4/5 environments. It is an essential tool for developers who need to monitor, debug, and track the behavior of their applications with precision. Below, we explore the key features and capabilities of this class. … Read more

Easy to use Hedging Class for MQL5 by Peter Mueller – library MetaTrader 5

Easy to use Hedging Class for MQL5 by Peter Mueller - library for MetaTrader 5
Input Parameters: OrderDistancePoints : Determines the distance in points from the current ask price for placing buy orders and from the bid price for placing sell orders. TPPoints : Specifies the take profit target in points. Startlotsize : Sets the initial lot size for trades. Gainperlot : Defines the desired gain per lot size. The … Read more

Examples from the book “Neural networks for algorithmic trading with MQL5” – EA MetaTrader 5

Examples from the book "Neural networks for algorithmic trading with MQL5" - expert for MetaTrader 5
The book “Neural networks for algorithmic trading with MQL5” is your go-to guide for learning how to use machine learning and neural networks in trading. This book is intended for algorithmic traders who want to learn how to create trading strategies using advanced artificial intelligence techniques. The book has 7 chapters that cover everything you … Read more

Working with sockets in MQL5 – library MetaTrader 5

Scheme of the interaction with MetaTrader 5 client terminal
This example will show you how to implement the realtime ticks transfer from MetaTrader 5 client terminal to external server application. The TCP protocol is used, it allows to transfer the data not only locally, but globally all over the Internet. The Winsock2 library (ws2_32.dll) is used for working with sockets. The direct calls of … Read more

MQL5 Wizard – Trade Signals Based on Price Crossover with Moving Average Indicator – EA MetaTrader 5

Figure 1. Trade signals based on price crossover with Moving Average
MQL5 Wizard allows to create the code of Expert Advisors automatically. See Creating Ready-Made Expert Advisors in MQL5 Wizard for the details. Here we will consider the strategy based on price crossover with Moving Average indicator. The strategy called “Signals based on price crossover with MA” (when creating EA automatically in MQL5 Wizard). The trade … Read more

MQL5 Wizard – Trade Signals Based on Three Moving Averages – EA MetaTrader 5

Figure 1. Trade signals, based on three moving averages
MQL5 Wizard allows to create the code of Expert Advisors automatically. See Creating Ready-Made Expert Advisors in MQL5 Wizard for the details. Here we will consider the trend strategy, based on three moving averages. The strategy called “Signals based on three EMA”. To determine the trend, it uses three exponentially smoothed moving averages: FastEMA, MediumEMA … Read more

MQL5 Wizard – Trade Signals Based on Price Crossover with Moving Average, confirmed by ADX – EA MetaTrader 5

Figure 1. Trade signals based on price crossover with Moving Average, confirmed by ADX
MQL5 Wizard allows to create the code of Expert Advisors automatically. See Creating Ready-Made Expert Advisors in MQL5 Wizard for the details. Here we will consider the strategy based on price crossover with Moving Average indicator, confirmed by ADX indicator. The strategy called “Signals based on price crossover with MA confirmed by ADX“ (when creating … Read more