MQL5 Algo Trading
387K subscribers
2.56K photos
2.56K links
The best publications of the largest community of algotraders.

Subscribe to stay up-to-date with modern technologies and trading programs development.
Download Telegram
The SWITCH statement in MQL5 offers an efficient alternative to multiple IF statements when checking for exact matches. Unlike IF, which evaluates conditions as true or false, SWITCH evaluates numerically, comparing the expression to defined CASE values. The statement’s differentiating feature is how it manages execution flow; using BREAK ensures the block exits correctly. It’s integral to insert BREAK before each new CASE to maintain code clarity and flow efficiency. Understanding the switch from numeric to logical evaluation within the CASE block is crucial. This foundational grasp will aid in managing the SWITCH statement’s complex behavior and prevent misinterpretation.

πŸ‘‰ Read | Signals | Share!

#MQL5 #MT5 #SWITCH
πŸ‘38❀21🀩5✍2πŸ‘¨β€πŸ’»2
The new indicator enables the visualization of an arbitrary seconds timeframe on the chart. Users can adjust settings such as the number of days to display; however, excessive days may lead to prolonged calculation times. It offers a choice between viewing bars or candlesticks. Upon comparison with a reference utility, the candlesticks appear to be accurately drawn. It's crucial to understand that this is an indicator, not a comprehensive seconds chart. Integrating other indicators onto this chart isn't possible, as they will reflect the values of the primary chart timeframe, not those of the seconds representation. This should be taken into account when using the indicator for analysis.

πŸ‘‰ Read | NeuroBook | Share!

#MQL5 #MT5 #Indicator
πŸ‘26❀11πŸ‘¨β€πŸ’»3
The multi-symbol indicator offers a streamlined method to assess price changes across various symbols listed in the Market Watch. Users define the timeframe with vertical lines, allowing for a clear comparison of market movements within specified dates. This feature is valuable for quickly understanding market dynamics and identifying trends.

The interface facilitates management, with date adjustments made using the mouse, while keyboard shortcuts enable swift symbol navigation. Such intuitive controls enhance user efficiency. Additionally, the indicator is designed to restart automatically upon launch or symbol change, ensuring uninterrupted functionality and up-to-date insights. This tool provides a practical solution for comprehensive market evaluation.

πŸ‘‰ Read | Freelance | Share!

#MQL5 #MT5 #Indicator
πŸ‘24❀10πŸ‘¨β€πŸ’»3
The Chande Kroll Stop indicator assists in setting precise stop loss levels. It features two lines on the price chart: the red line indicates the stop level for short positions, and the green line denotes the stop level for long positions. As a trend-following tool, it calculates average true range (ATR) values to accommodate market volatility. When price movements reach these lines, they signal potential position closures, providing strategic exits for traders.

First published in "The New Technical Trader," this indicator adapts to market conditions by factoring in maximum and minimum price values and standard deviations over a specific period. For traders handling highly volatile markets, the Chande Kroll Stop lines maintain a wider distance from the current price, whereas, in lower volatility, the lines draw nearer, ensuring timely reaction to pric...

πŸ‘‰ Read | Quotes | Share!

#MQL5 #MT5 #Indicator
πŸ‘29❀12πŸ‘¨β€πŸ’»3πŸ‘Ύ3
Algorithmic trading on MetaTrader 5 is elevated by understanding candlestick patterns through precise programming in MQL5. The discussion highlights creating a reusable candlestick pattern function library to enhance automated trading strategies. Developers can leverage relational operators and time series data to recognize both single and multi-candle patterns, improving the accuracy of historical backtesting and trading logic. Key technical concepts include ATR for dynamic pattern thresholds and MathAbs for consistent size measurement. This approach reduces manual chart analysis, offering traders and developers a streamlined, innovative methodology for harnessing market insights.

πŸ‘‰ Read | VPS | Share!

#MQL5 #MT5 #Indicator
πŸ‘28❀17πŸ‘¨β€πŸ’»5πŸŽ‰2
Preparing a trading system for the Strategy Tester in MQL5 involves integrating static economic event data. This enables reliable backtesting by utilizing a consistent dataset instead of relying on live feeds. Static data integration addresses the platform's limitations in storing historical economic events, enabling comprehensive backtesting of news-driven strategies.

To begin, users need to specify input parameters such as date ranges and filtering criteria for currency and impact levels. A structured approach is employed to load the news events from a resource file, applying these user-defined filters to simulate live conditions effectively.

Ensuring the data's availability during testing requires first gathering it in live mode, then storing it systematically. Data is typically stored in CSV files within the project resources, allowing it to be r...

πŸ‘‰ Read | Quotes | Share!

#MQL5 #MT5 #Algorithm
πŸ‘Œ12πŸ‘9❀6πŸ‘¨β€πŸ’»3⚑2
An innovative approach to moving average cross-over trading has been tested to optimize the strategy for MetaTrader 5 developers. By fixing moving average periods and applying one to opening prices and the other to closing prices, traders can control lag and improve sensitivity. The strategy is enhanced with a probabilistic model to identify market conditions conducive to success, reducing trades during unfavorable times. This algorithmic framework classifies high-probability setups, using MetaTrader 5 data and statistical modeling, to predict strategy profitability rather than direct market direction. The result is a more reliable trading model, improving strategy performance and Sharpe Ratio for EURUSD.

πŸ‘‰ Read | Calendar | Share!

#MQL5 #MT5 #Trading
❀28πŸ‘10πŸ‘¨β€πŸ’»5😁1
In recent updates on our replay/simulation application project, several refinements have been made to enhance system functionality. Although two primary bugs were resolved in the last session, a few minor issues still persist due to the transition from global terminal variables to new methodologies. This necessitates adapting and refining existing code rather than a complete overhaul. A key task addressed is reintroducing the fast-forward feature, which previously relied on now-obsolete global variables. By implementing a condition check within our control indicator functions, and adjusting select code snippets in our C_Replay.mqh file, the fast-forward mechanism now operates smoothly, addressing asynchronous issues between our service controls and user commands. Additionally, leveraging pre-built one-minute bars from the C_FileTicks class enables more e...

πŸ‘‰ Read | Calendar | Share!

#MQL5 #MT5 #Algorithm
πŸ‘21❀7πŸ‘Œ3⚑1πŸ‘¨β€πŸ’»1
Delve into the groundbreaking HyperDet3D algorithm, which revolutionizes 3D object detection by integrating scene-conditioned information into point cloud analysis. This approach rectifies ambiguities in object attributes using scene-level data, enhancing detection accuracy. The HyperDet3D model features a backbone encoder, object decoder, and detection head, which dynamically adjusts to varying input data. By leveraging scene-specific and scene-invariant knowledge, HyperDet3D ensures adaptive model performance. The innovative Multi-head Scene-Conditioned Attention module streamlines the fusion of prior knowledge with object features. Practical implementation in MQL5 facilitates the seamless application of these concepts for developers keen on advanced automated trading systems.

πŸ‘‰ Read | Forum | Share!

#MQL5 #MT5 #ObjectDetection
πŸ‘27❀8😁3⚑2πŸ‘¨β€πŸ’»2
CTsLogger provides a streamlined logging system tailored to MQL5 trading systems. It distinguishes itself by allowing selective debug mode activation, facilitating targeted diagnostics without overwhelming output. This feature enables detailed logging for specific components while keeping a leaner global log level, simplified further with the ability to toggle debugging with a single action.

The system emphasizes user convenience, offering straightforward initialization and intuitive logging function calls. Its modular design supports a hierarchical identification system, allowing logical organization of code sections, and boasts robust state management capabilities, such as pausing and resuming debug configurations without data loss. CTsLogger's resilience ensures operational continuity, even under file system disruptions, by falling back to terminal o...

πŸ‘‰ Read | NeuroBook | Share!

#MQL5 #MT5 #Debugging
πŸ‘25❀9πŸ’”2πŸ‘¨β€πŸ’»2⚑1
The outlined strategy involves taking short positions when the price reaches the high of n-lookback bars, aiming for a return to the mean of n-lookback. Conversely, it suggests going long when the price hits the low of n-lookback bars, with the target again being the mean. Utilizing this approach on one-minute OHLC data may lead to misleading simulations. The frequency of trades and the inherent noise in one-minute bars can distort outcomes. The strategy could be less reliable due to the high number of false signals typical in such short intervals. Thorough backtesting with robust data and risk management considerations is crucial before moving forward with such strategies.

πŸ‘‰ Read | Calendar | Share!

#MQL5 #MT5 #Strategy
πŸ‘21❀7πŸ‘¨β€πŸ’»3✍2πŸ‘Œ2
The current implementation of the Expert Advisor (EA) highlights some challenges and opportunities for improvement. Existing resources aid trading activities, yet issues with visualization and chart resizing persist, possibly causing screen clutter until refreshed. These drawbacks do not affect the trading functionality but could hinder user experience. Enhancements in volume analysis and order flow visualization are suggested, offering more precise tools for traders.

Accurate market behavior analysis often depends on evaluating price accumulation regions and tracking price movements with time-sensitive adjustments. Implementing a flexible tracking mechanism allows traders to better understand market tests versus trend reversals. By modifying the volume display functionality, capturing trades and price movements becomes clearer.

Chart resizing issues were ...

πŸ‘‰ Read | Forum | Share!

#MQL5 #MT5 #EA
πŸ‘42❀22πŸŽ‰5πŸ‘¨β€πŸ’»4⚑1πŸ‘Œ1
The Currency Strength Meter for MetaTrader 5 provides users the ability to assess the relative strength of various currency pairs across different timeframes. This utility allows traders to make informed decisions based on the comparison of multiple currencies. Originally designed for MetaTrader 4, the tool known as "Currency Strength Giraia 28 pairs TRO MODIFIED" has been successfully adapted for MetaTrader 5. The configurable timeframe parameter adds flexibility, enabling users to adjust their analysis according to their specific trading strategies. This conversion enhances the usability of the renowned indicator, aligning it with the advanced features offered by MetaTrader 5 while maintaining its core functionality.

πŸ‘‰ Read | Freelance | Share!

#MQL5 #MT5 #AlgoTrading
πŸ‘29❀18πŸ‘¨β€πŸ’»3⚑1
Explore Kohonen Maps in MQL5 for innovative algorithmic trading. This article discusses using Kohonen Maps to translate complex multi-dimension price data into a simplified single-dimension format, facilitating more efficient trading decisions. Dive into technical details of creating classes and layers, including Feed, Functor, and Neuron classes, leveraging array lists and hash maps. The unique single-layer neuron structure differs from traditional networks, focusing on competitive learning for adjusting output. Practical insights on testing show how Kohonen Maps can refine quantization and topological errors, aiding traders in optimizing strategies through modeling and testing, providing promising results in dynamic market scenarios.

πŸ‘‰ Read | Calendar | Share!

#MQL5 #MT5 #Kohonen
πŸ‘47❀16⚑7πŸ‘¨β€πŸ’»5
Candle signature with example is a beneficial tool for traders in the research and development of identifying single candlestick patterns. It enables users to store these patterns and make inquiries to identify potential matches in the future. Utilizing datasets like open, high, low, close, and comment, traders can input custom values to search for similar candlestick patterns. The script employs a fuzzy matching algorithm to maximize the potential for pattern recognition. Users have the option to add a tolerance level, considering that exact pattern repetitions are uncommon. This feature enhances the script's utility for those looking to refine their trading strategies based on candlestick analysis.

πŸ‘‰ Read | Freelance | Share!

#MQL5 #MT5 #Script
πŸ‘23❀19⚑1πŸ‘¨β€πŸ’»1
Unsupervised learning is gaining traction in AI, offering models the ability to train with only raw data, thus reducing the labor in preparing reference values. Compared to supervised learning, which depends on labeled data, unsupervised learning thrives on detecting patterns independently, useful in scenarios like anomaly detection or data dimensionality reduction. K-means clustering is a prime example, efficient for clustering tasks. It initializes random cluster centers and iteratively assigns data points based on proximity. The algorithm adjusts cluster centers until stability is achieved, and cluster evaluation can be done by analyzing the average deviation of points from their centers.

πŸ‘‰ Read | CodeBase | Share!

#MQL5 #MT5 #Unsupervised
πŸ‘48❀33⚑4πŸ”₯3πŸ‘Œ3πŸŽ‰1πŸ‘¨β€πŸ’»1
A modified MQL4 indicator now includes an automatic Fibonacci feature. It streamlines technical analysis by automatically plotting Fibonacci retracement and projection levels using selected swing highs and lows. Users can select which swing index, such as the 1st, 2nd, or 3rd swing, to use as the Fibonacci anchor point. This enhancement removes the need for manual drawing while maintaining the accuracy of analysis. There is no claim on the rights of the original indicator; the modification solely aims to improve user experience by enhancing usability. This update facilitates more efficient and effective technical analysis.

πŸ‘‰ Read | Docs | Share!

#MQL4 #MT4 #Indicator
❀24πŸ‘17✍5πŸŽ‰1πŸ‘¨β€πŸ’»1
The Kuskus Starlight is a technical indicator designed for oscillator functions, leveraging a Fisher price transformation to aid traders in trend identification and market reversals. It normalizes over various periods and includes adjustable smoothing for custom responsiveness. This tool serves as a confirmation component within trading systems, enhancing trade signal validation. Initially discovered through platforms like Stonehill Forex and NNFX, it is acknowledged for confirming indicators within trading strategies, with origins linked to Stonehill Forex in 2007 and NNFX in 2017.

MT5 users now have access to the Kuskus Starlight indicator thanks to a newly coded version that adapts the original MT4 design, preserving its core algorithm. The MT5 adaptation remains aligned with the primary functionality intended by its MT4 predecessor. Indicator s...

πŸ‘‰ Read | Signals | Share!

#MQL5 #MT5 #Indicator
πŸ‘21❀10πŸ‘¨β€πŸ’»5πŸ”₯4πŸ‘Œ1πŸ†1
The tool serves as a monitoring system for Expert Advisors (EAs), allowing traders to efficiently track historical and current drawdown levels. By inputting expected historical maximum drawdown figures derived from backtesting or past trade data, traders have a clear visual benchmark for assessing EA performance. Real-time monitoring ensures that any breach of critical drawdown levels can be swiftly addressed.

The tool offers smart notifications, sending alerts via the MetaTrader app when new drawdown records are achieved, or at regular intervals set by the user. This facilitates informed decision-making without unnecessary message fatigue. Traders can also log drawdown data to external CSV or TXT files for post-trade analysis.

Geared toward users of automated or semi-automated trading systems, the tool is ideal for those needing to reconcile strateg...

πŸ‘‰ Read | Docs | Share!

#MQL5 #MT5 #Indicator
πŸ‘23❀13πŸŽ‰7πŸ”₯1πŸ†1πŸ‘¨β€πŸ’»1
The Volume Oscillator measures market trends using two volume-based moving averages. It calculates the strength or weakness of a trend by analyzing price movements with volume changes. When the Volume Oscillator is above the zero line, it suggests that the current trend direction is supported by adequate volume, signaling a strong market movement either in an uptrend or downtrend.

Conversely, if the Volume Oscillator falls below the zero line, it indicates a weak market trend due to insufficient volume support. This could signal stagnation or a potential trend reversal. Negative divergences can often hint at an impending reversal. The indicator's oscillation between positive and negative values provides insights into the market's support for price movements. Understanding these signals helps in assessing the anticipated strength or weakness of ongoing tr...

πŸ‘‰ Read | VPS | Share!

#MQL5 #MT5 #Indicator
❀24πŸ‘14⚑8πŸ†3πŸŽ‰2πŸ‘¨β€πŸ’»2🀯1