Discover how to enhance your trading charts with custom objects in MQL5! This article discusses how to create and modify chart objects to provide visual clarity and actionable insights for traders and developers. Learn to use objects like rectangles, trend lines, and text labels to highlight key price levels, monitor trades, and display real-time performance data. This practical guide walks you through building an Expert Advisor that visualizes entry points, stop losses, and take profits directly on the chart, dynamically updates with market changes, and provides historical trade analysis. Perfect for those looking to deepen their algorithmic trading skills with MQL5.
#MQL5 #MT5 #MQL5 #Trading
Read more...
#MQL5 #MT5 #MQL5 #Trading
Read more...
β€42π28β8π4π€‘3π¨βπ»3
New feature added to allow direct specification of the starting point for the Parabolic SAR. Users can now set the initial value for more precise control over the Parabolic SAR calculation. Parameters include Trailing Mode options: None, Trailing Fixed, and Trailing Fixed Parabolic SAR. This enhancement enables tailored adjustments in your technical analysis, offering customizable options to fit diverse trading strategies. This update aims to provide advanced users with greater flexibility in setting and refining their indicators, contributing towards more accurate market predictions and better-informed decision-making.
#MQL5 #MT5 #Indicator #AlgoTrading
Read more...
#MQL5 #MT5 #Indicator #AlgoTrading
Read more...
π37β€13π3π¨βπ»2π1
Streamline Your Algorithmic Trading with Advanced EA Integration
Harness the power of efficient EA design in MetaTrader 5! Our strategy-centric approach seamlessly integrates multiple trading strategies into a single Expert Advisor (EA), optimizing performance and managing drawdown risks. We employ genetic optimization to fine-tune strategy parameters across symbols and timeframes, ensuring robust trading results.
Utilize optimization cache files for storing intermediate results and leverage SQLite for scalable database management. Our systematic process, including event-specific handlers and data frames, ensures precise data collection from MetaTrader 5 testing agents. This comprehensive framework is ideal for both seasoned developers and those new to EA development. Dive in and elevate your trading strategies!
#MQL5 #MT5 #EA #Strategy
Read more...
Harness the power of efficient EA design in MetaTrader 5! Our strategy-centric approach seamlessly integrates multiple trading strategies into a single Expert Advisor (EA), optimizing performance and managing drawdown risks. We employ genetic optimization to fine-tune strategy parameters across symbols and timeframes, ensuring robust trading results.
Utilize optimization cache files for storing intermediate results and leverage SQLite for scalable database management. Our systematic process, including event-specific handlers and data frames, ensures precise data collection from MetaTrader 5 testing agents. This comprehensive framework is ideal for both seasoned developers and those new to EA development. Dive in and elevate your trading strategies!
#MQL5 #MT5 #EA #Strategy
Read more...
β€20π15π¨βπ»3β2π1
Part 5 of the series continues the integration of MetaQuotes Language 5 (MQL5) with Telegram, focusing on allowing the Expert Advisor (EA) in MetaTrader 5 (MT5) to receive and interpret commands from Telegram users. The objective is to enable two-way communication, where the EA not only sends messages but also intelligently responds to user commands.
First, the necessary environment is set up by including essential MQL5 libraries for trade management and data handling. This prepares the EA to manage complex data structures received from Telegram.
Subsequently, classes are created to retrieve and process chat updates from JSON data returned by the Telegram API. The classes parse the JSON data to extract chat updates and user commands, essential for dynamic communication between MT5 and Telegram.
The EA decodes and interprets incoming data from the Telegr...
#MQL5 #MT5 #EA #AlgoTrading
Read more...
First, the necessary environment is set up by including essential MQL5 libraries for trade management and data handling. This prepares the EA to manage complex data structures received from Telegram.
Subsequently, classes are created to retrieve and process chat updates from JSON data returned by the Telegram API. The classes parse the JSON data to extract chat updates and user commands, essential for dynamic communication between MT5 and Telegram.
The EA decodes and interprets incoming data from the Telegr...
#MQL5 #MT5 #EA #AlgoTrading
Read more...
π24β€19π¨βπ»3β2β‘1π₯1π1
Enhance your trading strategy with a dynamic multi-pair Expert Advisor (EA) designed to capitalize on correlations and inverse correlations between currency pairs. By defining a primary currency pair to signal trades for other pairs, this EA optimizes performance during high-impact market events. The system is flexible, allowing traders to input and modify currency pairs and uses the RSI indicator to generate trading signals. Efficiently trade correlated pairs dynamically, adjusting for market conditions. This innovative approach not only boosts consistency but also leverages relationships between currency pairs to maximize trading opportunities and manage risks effectively. Explore smarter trading today.
#MQL5 #MT5 #Algorithm #EA
Read more...
#MQL5 #MT5 #Algorithm #EA
Read more...
π22β€9β‘3π2π¨βπ»2
Dive into the world of Gaussian Process Kernels in algorithmic trading with this insightful exploration of linear and MatΓ©rn kernels! Linear kernels are ideal for capturing long-term trends with computational efficiency, making them perfect for assets with clear upward or downward price movements. On the other hand, the MatΓ©rn kernel, with its adjustable smoothness, excels at modeling both trending and volatile data, providing nuanced forecasts. By implementing these kernels in MetaTrader 5 via MQL5, traders and developers can leverage sophisticated models to navigate the complexities of financial time series, optimize performance, and handle noisy data with precision.
#MQL5 #MT5 #EA #Algorithm
Read more...
#MQL5 #MT5 #EA #Algorithm
Read more...
π15β10β€5π¨βπ»2
Potentially infinite ways exist for modern investors to integrate AI into their trading strategies. In a series of articles, we explore the vast range of AI applications in trading. Our goal is to identify a strategy suitable for specific investor profiles.
The Financial Times Stock Exchange 100 (FTSE100) tracks the performance of the 100 largest companies on the London Stock Exchange. Created in 1984 with 1,000 points, it trades around 8,000 points. Companies within the index are weighted based on market capitalization.
UK government issues debt instruments called gilts. Gilts are fixed-income securities available in two types: conventional and index-linked. Conventional gilts pay a fixed coupon, while index-linked adjust for inflation. Gilts offer predictable income and low default risk.
Bonds and stocks have an inverse relationship: when stock ...
#MQL5 #MT5 #AITrading #algorithm
Read more...
The Financial Times Stock Exchange 100 (FTSE100) tracks the performance of the 100 largest companies on the London Stock Exchange. Created in 1984 with 1,000 points, it trades around 8,000 points. Companies within the index are weighted based on market capitalization.
UK government issues debt instruments called gilts. Gilts are fixed-income securities available in two types: conventional and index-linked. Conventional gilts pay a fixed coupon, while index-linked adjust for inflation. Gilts offer predictable income and low default risk.
Bonds and stocks have an inverse relationship: when stock ...
#MQL5 #MT5 #AITrading #algorithm
Read more...
π31β€13π5π¨βπ»4
A script has been developed to enhance chart analysis by creating a dynamic text object. This text not only rotates but also adjusts its position according to price levels. It changes color and content in real-time based on its location, providing a visually engaging and informative element to the chart. Such functionality can be especially advantageous for traders seeking to add annotations or dynamic markers to their trading charts, enhancing the situational awareness and decision-making processes. This tool seamlessly integrates with chart environments, aiding in the visualization of important market data.
#MQL4 #MT4 #script #Indicator
Read more...
#MQL4 #MT4 #script #Indicator
Read more...
π17β€5π2π¨βπ»2
The PrevDayLines.mq4 script is designed for MetaTrader 4, automatically plotting three essential price levels from the previous trading day on your chart. These levels include the highest price (Max), the lowest price (Min), and the average price (Avg), offering a clear visual reference for key support and resistance areas.
The script is fully customizable, permitting adjustments to the color, thickness, and style of lines to match user preferences.
Key features include automatic drawing of these price levels, customizable visuals with parameters for color, width, and line style, and straightforward integration, allowing immediate display on any chart. This tool is beneficial for traders who use historical price levels to identify potential market turning points.
#MQL4 #MT4 #EA #script
Read more...
The script is fully customizable, permitting adjustments to the color, thickness, and style of lines to match user preferences.
Key features include automatic drawing of these price levels, customizable visuals with parameters for color, width, and line style, and straightforward integration, allowing immediate display on any chart. This tool is beneficial for traders who use historical price levels to identify potential market turning points.
#MQL4 #MT4 #EA #script
Read more...
π18β€14π3π¨βπ»1
The CDebugLogger class offers a comprehensive logging solution optimized for MQL4/5 environments. It serves as a vital tool for developers focused on precise application monitoring and debugging.
**Key Features:**
- **Multiple Log Levels:** Supports INFO, WARNING, ERROR, and DEBUG levels, enabling developers to filter messages by significance.
- **Timestamp Inclusion:** Customizable timestamps for logging, essential for time-sensitive issue tracking.
- **File Logging:** Includes robust options for file logging, allowing specification of log file paths and CSV format for easier analysis.
- **Contextual Information:** Allows inclusion of function signatures, file names, and line numbers in logs for precise issue pinpointing.
- **Silent Keywords:** Ability to silence logs containing specific keywords to avoid logging sensitive information.
- **Filter Keywords:** En...
#MQL5 #MT5 #MQL #EA
Read more...
**Key Features:**
- **Multiple Log Levels:** Supports INFO, WARNING, ERROR, and DEBUG levels, enabling developers to filter messages by significance.
- **Timestamp Inclusion:** Customizable timestamps for logging, essential for time-sensitive issue tracking.
- **File Logging:** Includes robust options for file logging, allowing specification of log file paths and CSV format for easier analysis.
- **Contextual Information:** Allows inclusion of function signatures, file names, and line numbers in logs for precise issue pinpointing.
- **Silent Keywords:** Ability to silence logs containing specific keywords to avoid logging sensitive information.
- **Filter Keywords:** En...
#MQL5 #MT5 #MQL #EA
Read more...
π28β€9π5π¨βπ»2
Discover a new chart type for MetaTrader 5βideal for swing, position, and portfolio trading! We're creating Mountain and Iceberg charts using simple MQL5 code. These charts enhance profit/loss visibility at a glance with different colors, making them user-friendly for long-term traders. Despite its simplicity, this coding approach is robust and integrates seamlessly with your favorite indicators and EAs. This introduction to custom charting in MetaTrader 5 highlights its flexibility and potential, proving that with a little creativity, this platform can offer far more than many realize. Dive in and elevate your trading analysis!
#MQL5 #MT5 #Indicator #MQL5
Read more...
#MQL5 #MT5 #Indicator #MQL5
Read more...
π39β€22β‘7π3β2π¨βπ»1
A new Expert Advisor (EA) aims to monitor support and resistance breaks on H4 and H1 timeframes. Users only need to configure their charts to the H1 timeframe and apply the EA. After configuration, provide your Meta Quote ID from your phone to MetaTrader on your PC. This setup enables receiving notifications on breakout events for H1, H4, and moving averages. The process is straightforward, ensuring you stay updated on critical market movements efficiently.
#MQL4 #MT4 #EA #Strategy
Read more...
#MQL4 #MT4 #EA #Strategy
Read more...
π19β€13β‘12π¨βπ»2
Improving library classes:
Add code in \MQL5\Include\DoEasy\Defines.mqh to include the new graphical element type. Create an enumeration for standard images like Info, Warning, Error icons. Define new integer properties increasing the total from 122 to 129. Include new string properties and criteria for sorting graphical elements.
Update \MQL5\Include\DoEasy\Data.mqh to add new message indices and corresponding text messages. Modify \MQL5\Include\DoEasy\Objects\Graph\GBaseObj.mqh to return new control descriptions via the TypeElementDescription() method.
The \MQL5\Include\DoEasy\Objects\Graph\GCnvElement.mqh file requires methods for writing pointers to base objects for ToolTip associations. Ensure element opacity and display flags can be overridden in inherited classes. Introduce SetOpacityDraw method for shadow objects.
In \MQL5\Include\DoEasy\Obje...
#MQL5 #MT5 #Tooltip #WinForms
Read more...
Add code in \MQL5\Include\DoEasy\Defines.mqh to include the new graphical element type. Create an enumeration for standard images like Info, Warning, Error icons. Define new integer properties increasing the total from 122 to 129. Include new string properties and criteria for sorting graphical elements.
Update \MQL5\Include\DoEasy\Data.mqh to add new message indices and corresponding text messages. Modify \MQL5\Include\DoEasy\Objects\Graph\GBaseObj.mqh to return new control descriptions via the TypeElementDescription() method.
The \MQL5\Include\DoEasy\Objects\Graph\GCnvElement.mqh file requires methods for writing pointers to base objects for ToolTip associations. Ensure element opacity and display flags can be overridden in inherited classes. Introduce SetOpacityDraw method for shadow objects.
In \MQL5\Include\DoEasy\Obje...
#MQL5 #MT5 #Tooltip #WinForms
Read more...
π42β€35π7π₯5π¨βπ»3
The Dual Profit Closer EA enhances trading strategies by managing and closing buy and sell orders based on defined profit thresholds.
**Features:**
**Separate Buy & Sell Order Management:** The EA tracks buy and sell orders individually, closing each at the user-specified profit level, allowing for precise control over trading strategies.
**Real-Time Profit Tracking:** Provides live updates of overall buy and sell profits directly on the chart, keeping traders informed without the need for reviewing multiple reports.
**Customizable Profit Thresholds:** Users can easily set and adjust profit levels for both types of orders, enabling automatic order closure at optimal gain points.
**Avoid Broker Manipulation:** Instantly closes deals when overall profit for either buy or sell orders reaches the threshold, bypassing the need to set take profit (TP) or stop ...
#MQL4 #MT4 #EA #Scalper
Read more...
**Features:**
**Separate Buy & Sell Order Management:** The EA tracks buy and sell orders individually, closing each at the user-specified profit level, allowing for precise control over trading strategies.
**Real-Time Profit Tracking:** Provides live updates of overall buy and sell profits directly on the chart, keeping traders informed without the need for reviewing multiple reports.
**Customizable Profit Thresholds:** Users can easily set and adjust profit levels for both types of orders, enabling automatic order closure at optimal gain points.
**Avoid Broker Manipulation:** Instantly closes deals when overall profit for either buy or sell orders reaches the threshold, bypassing the need to set take profit (TP) or stop ...
#MQL4 #MT4 #EA #Scalper
Read more...
π38β€18π4π¨βπ»3π2
A new user-centric dialog panel is now available, offering dynamic calculations and displaying the maximum lot size permissible on brokerage accounts across various order types: buy, sell, pending buy, and pending sell. This tool bases its calculations on the available margin, ensuring accuracy for numerous securities including forex pairs, commodities, cryptocurrencies, and indices. The intuitive design allows the dialog to be minimized or closed directly from the panel, enhancing user experience without compromising functionality. This enhancement aims to streamline trading operations and improve decision-making efficiency for professional traders and developers.
#MQL5 #MT5 #Algorithm #Indicator
Read more...
#MQL5 #MT5 #Algorithm #Indicator
Read more...
β€22π11π¨βπ»3π1π1
An in-depth analysis focuses on Deriv's Boom 1000 synthetic market. This market is marked by its volatile bull and bear candles, making it notoriously unpredictable. The method of sending limited tick data results in breached stop losses with guaranteed slippage, hence many consider buy opportunities in trading strategies given its dominant bullish movements.
Machine learning techniques were employed to model relations and predict price movements. 100,000 rows of M1 data with RSI indicator readings were collected. Exploratory data analysis revealed an 83% correlation between falling RSI readings and falling prices, but the RSI had a weak correlation of 0.016 with price levels. The dataset was split for training and validation.
Two neural network classifiers were used: one for predicting price changes and another for RSI changes. The RSI model achieved an ac...
#MQL5 #MT5 #Strategy #AI
Read more...
Machine learning techniques were employed to model relations and predict price movements. 100,000 rows of M1 data with RSI indicator readings were collected. Exploratory data analysis revealed an 83% correlation between falling RSI readings and falling prices, but the RSI had a weak correlation of 0.016 with price levels. The dataset was split for training and validation.
Two neural network classifiers were used: one for predicting price changes and another for RSI changes. The RSI model achieved an ac...
#MQL5 #MT5 #Strategy #AI
Read more...
π23β€15π7π¨βπ»2π1
Discover the intricacies of the Smart Money Optimal Control (SMOC) advisor, designed for advanced Forex trading. Leveraging stochastic modeling and control optimization, SMOC uses Model Predictive Control (MPC) to anticipate market moves. Key features include adaptive forecast horizons and lot sizes tailored to market volatility and drawdown, dynamic stop loss and take profit based on the Average True Range (ATR), and a blend of technical indicators like SMA, RSI, and ATR for trend and volatility analysis. While offering sophisticated risk management, SMOC also tackles computational demands and the risk of overfitting, making it a potent tool for traders.
#MQL5 #MT5 #Algorithm #EA
Read more...
#MQL5 #MT5 #Algorithm #EA
Read more...
π21β€16π2π¨βπ»2π€2π€―1
Algorithmic trading efficiency demands seamless communication between trading systems and human administrators. This article presents methods to enhance the Administrator Messaging Interface using MQL5, emphasizing quick messaging and responsive interfaces.
Define responsiveness within the MQL5 GUI, focusing on immediate feedback, smooth performance, dynamic updates, scalability, and error handling. These components are crucial for timely trading actions and an intuitive interface.
Quick messages facilitate standard responses, error notifications, and routine commands. Include buttons in the Admin Panel for predefined messages, reducing manual input and ensuring rapid, consistent communication.
Implement responsive control buttonsβminimize, maximize, and closeβusing the CButton class. Enhance flexibility through customizable quick messages, managing cha...
#MQL5 #MT5 #AlgoTrading #EA
Read more...
Define responsiveness within the MQL5 GUI, focusing on immediate feedback, smooth performance, dynamic updates, scalability, and error handling. These components are crucial for timely trading actions and an intuitive interface.
Quick messages facilitate standard responses, error notifications, and routine commands. Include buttons in the Admin Panel for predefined messages, reducing manual input and ensuring rapid, consistent communication.
Implement responsive control buttonsβminimize, maximize, and closeβusing the CButton class. Enhance flexibility through customizable quick messages, managing cha...
#MQL5 #MT5 #AlgoTrading #EA
Read more...
π36β€26π¨βπ»8β‘4π₯3π2π€£1
A new library for multicurrency Expert Advisors helps accurately determine new bar events across different instruments. In a multicurrency scenario, new bars form at varying times for each instrument. Since the EA operates on a single instrument's chart, it is crucial to identify whether a new bar has formed in the OnTick() event handler for other instruments. This library offers a solution by storing the time of the first tick for each required instrument at every tick. When a new bar starts, this time updates and remains constant until the next bar.
The library simplifies the process by managing the necessary variables for different instruments and time periods. Users only need to call `UpdateNewBar()` at the beginning of OnTick() and use `IsNewBar(symbol, timeframe)` to check for new bar events. The library must be included by adding `NewBarEvent.mqh`. ...
#MQL5 #MT5 #EA #Indicator
Read more...
The library simplifies the process by managing the necessary variables for different instruments and time periods. Users only need to call `UpdateNewBar()` at the beginning of OnTick() and use `IsNewBar(symbol, timeframe)` to check for new bar events. The library must be included by adding `NewBarEvent.mqh`. ...
#MQL5 #MT5 #EA #Indicator
Read more...
π18β€10π¨βπ»4π€‘2π1π1
MetaTrader 5 developers, elevate your trading strategies with a sophisticated trailing stop mechanism using the Parabolic SAR indicator. This method automates StopLoss adjustments, enhancing trade protections without premature exits. Learn how to integrate a specialized trailing function in MQL5, leveraging Parabolic SAR for automatic price adaptation. Delve into creating an Expert Advisor to handle StopLoss via precise criteria checks, maintaining StopLevel and FreezeLevel constraints. Utilize \CTrade\ class for streamlined trade functions, ensuring seamless StopLoss modifications. This approach not only shields gains but also optimizes position management in trending markets. Enhance your algorithmic trading efficiency with these advanced techniques!
#MQL5 #MT5 #EA #Indicator
Read more...
#MQL5 #MT5 #EA #Indicator
Read more...
π30β€14π4π2π¨βπ»2
The Patch Time Series Transformer (PatchTST) offers an innovative method for time series forecasting. By segmenting time series into patches, it leverages Transformer architecture to capture complex semantic relationships between data points more effectively than traditional point-level analysis. The approach reduces computational complexity, enhances learning from extended data windows, and improves representation learning. PatchTST treats multivariate time series as independent univariate sequences, optimizing analysis while maintaining efficiency. The article also discusses practical implementation in MQL5, emphasizing efficient data preparation through OpenCL for improved algorithm performance. PatchTST showcases its potential in anomaly detection, classification, and long-term forecasting, making it a robust solution for advanced time series a...
#MQL5 #MT5 #AITrading #DeepLearning
Read more...
#MQL5 #MT5 #AITrading #DeepLearning
Read more...
π41β€31π4π¨βπ»4π2