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
Forecasting future time series prices is crucial in financial markets. Traditional methods often rely on autocorrelation, yet modern approaches like the Transformer model utilize Self-Attention for dynamic autocorrelation. There's a rising interest in frequency analysis, aiding in overcoming autocorrelation complexities. Despite these advances, many methods using the Direct Forecast (DF) paradigm ignore autocorrelation in predicted values, misaligning assumptions and resulting in suboptimal forecasts.

The FreDF method offers a solution by addressing autocorrelation in frequency domain prediction, enhancing DF while retaining its efficiency. It introduces a frequency-based forecast calibration, tested to outperform contemporary methods. This flexible approach integrates with various models, including MQL5. Implementing FreDF involves transforming...
#MQL5 #MT5 #Forecasting #AlgoTrading

Read more...
17👍7👨‍💻3👌21
Explore the realm of correlation analysis with a deep dive into Pearson's chi-square test of independence and the correlation ratio. This article elucidates how these tools evaluate dependencies between random variables, offering insights beyond mere linear analysis, particularly in realms like stock price increments. Highlighting features like the CHI2Test indicator, learn to detect hidden relationships and assess the non-linearity of dependencies. Comprehensive scripts like Crosstab and Crosstab_Models enhance your ability to test hypotheses related to correlation dependence and linearity. These techniques are crucial for traders and developers aiming to uncover complex relationships and refine their algorithmic trading strategies.
#MQL5 #MT5 #Statistics #DataAnalysis

Read more...
21👍12👌10👨‍💻5🔥1
The indicator represents the status of two moving average indicators, displaying results as lines of colored squares. It uses clrYellowGreen to signify the absence of a trend, clrBlue to denote an upward trend, and clrRed for a downward trend. Users can identify these trends at a glance through the color-coded presentation. This tool is useful for adding clarity to market analysis, providing a straightforward visual representation of trends, eliminating the need for complex interpretation of data. This approach makes it easier to track market changes efficiently and allows for quick adjustments to trading strategies based on trend evaluation. It aids in efficient market decision-making by offering instant visual feedback.
#MQL5 #MT5 #Indicator #Trading

Read more...
👍33186👨‍💻3
Lines play a crucial role in technical trading by marking important price levels to aid decision-making. Automation of these processes through MQL5 can streamline trading strategies. The discussion covers three key line types: trend lines, support, and resistance levels.

Trend lines indicate market trends. In an upward trend line, price rebounds upwards from at least three points along the drawn line. Conversely, a downward trend line shows price bouncing downwards. Code in MQL5 can automate drawing and updating these lines as market conditions change.

Support levels are zones below current prices where buying interest may lead to upward price movement. Similarly, resistance levels, positioned above current prices, highlight selling interest which could push prices downwards. MQL5 scripts can automate identifying and updating these levels to assist ...
#MQL5 #MT5 #Trading #AlgoTrading

Read more...
👍9777👨‍💻98🔥7👀6👌2
The WeekDays indicator provides an efficient method to view the Day Of Week, Week Of Year, Day Of Year, or Bar Index directly within the Data Window. It updates dynamically with mouse movements, reflecting the current day's name in the left column and customizable details in the right, based on settings for WholePart and FractionalPart. These settings enable users to display specific data such as Day Of Week, Week Of Year, Day Of Year, Bar Index, or None. Values are integrated into a single floating point stored in the indicator buffer, invisible on the chart due to the DRAW_NONE style, as these are synthetic.

Customization options include showing labels on the chart, defining FontName, FontSize, and FontColor, setting padding from chart edges, and choosing the alignment and rotation angle for middle alignment. Default clrNONE for FontColor results in...
#MQL5 #MT5 #Indicator #WeekDays

Read more...
👍4923😁2👨‍💻1👀1
Reinforcement learning presents a significant branch of machine learning, distinct from supervised and unsupervised methods. It operates on a trial-and-error basis, much like adaptive behaviors seen in organic systems. The main components include an Agent and an Environment, where the Agent learns strategies through interaction, receiving Rewards based on actions taken within the Environment. These rewards can be immediate or delayed.

Reinforcement learning differs from previous methods in that it doesn't require a static training sample. Instead, the Agent continuously interacts and learns from changing states. The Cross Entropy method within reinforcement learning handles finite states and actions, refining strategies iteratively based on performance metrics. Implementing these in MQL5 involves leveraging clustering algorithms like k-means to define possi...
#MQL5 #MT5 #RL #Algorithm

Read more...
👍2492👨‍💻2
The Expert Advisor (EA) integrates signals from the 'VIDYA N Bars Borders' custom indicator to make trading decisions. It evaluates current profit status before acting on a signal. If the profit is negative, the EA implements the 'Position Increase Ratio' setting, executing the signal with an increased lot size. This EA is capable of managing both 'BUY' and 'SELL' positions simultaneously. All open positions are closed once the specified 'Profit target' in monetary terms is achieved. This approach allows for dynamic adjustment of lot sizes based on profit evaluation, providing flexibility and potential for optimized trading outcomes.
#MQL5 #MT5 #EA #Trading

Read more...
👍2111💯4👨‍💻211
Overfitting in machine learning occurs when a model becomes too tailored to noise in the dataset, reducing its generalization capability. This leads to poor performance on unseen data. Traditional solutions like early stopping help but can limit model potential. A 2019 paper from Harvard suggests that for certain tasks, overfitting could be mitigated by training models for extended iterations, observing a "double descent" in test error. This approach can outperform perpetual fine-tuning but demands significant computational resources.

Practical applications using models like neural networks reveal inconsistencies, emphasizing the importance of parameter selection. Advancements in structured exploration of algorithmic landscapes can optimize these efforts.
#MQL5 #MT5 #ML #AITrading

Read more...
👍188👨‍💻42🔥1
Recent updates to the replay/simulator system address stability and security concerns highlighted in developing the control indicator. Integration with modules like the mouse indicator is refined, ensuring consistent functionality without reliance on redundant code. The control indicator now leverages inheritance for improved performance, and changes in access patterns to the C_Terminal class facilitate better interaction with charts, handling mixed usage involving LIVE, DEMO, and replay systems.

The mouse indicator source code sees subtle yet significant updates, emphasizing the importance of leaving critical inputs untouched to avoid system instability. Developers are encouraged to thoroughly understand these new structures. Familiarity with module integration and class inheritance will be crucial for effective implementation and future-proofing of...
#MQL5 #MT5 #Indicator #Algorithm

Read more...
21👍14👨‍💻32
A new MT5 version of the indicator has been developed and is now available. This version has been specifically optimized for the MetaTrader 5 platform, ensuring seamless integration and enhanced performance. Users can expect improved accuracy and efficiency. The development process focused on compatibility and reliability, catering to the needs of traders seeking robust analytical tools. This updated indicator offers users additional features that can aid in making more informed trading decisions. To take advantage of these enhancements, ensure your trading platform is updated to support the latest developments.
#MQL5 #MT5 #Indicator #Trading

Read more...
👍2812💯4👨‍💻2👌1
The article discusses reinforcement learning through the lens of Deep Q-learning, focusing on advancements since the publication by the DeepMind team in 2013. Deep Q-learning enhances the standard Q-function environment interaction model by incorporating neural networks to address trading-related challenges. Q-functions are explained as methods for linking current states, actions, and rewards, approximated through interaction cycles.

Moving beyond the basics, Deep Q-learning utilizes neural networks to overcome limitations of finite state-action pairs encountered in previous models, employing methods like dynamic programming and Bellman optimization. Experience replay is crucial, enabling agents to optimize learning by shuffling states stored in memory buffers for randomness and long-term accuracy.

Supervised learning concepts are contrasted with...
#MQL5 #MT5 #DeepLearning #AITrading

Read more...
👍2418👨‍💻5👌1
The Hammer Indicator analyzes candlestick formations on MetaTrader 5 charts, specifically focusing on hammers and inverted hammers, which are indicators of potential reversal points. This indicator evaluates candlestick structure based on three customizable parameters: MaxRatioShortWick, MinRatioLongWick, and MinCandleSize. These parameters help in identifying patterns by setting thresholds for the size and ratios of wicks to the candlestick body, filtering out less significant formations.

Hammers, featuring a small body and long lower wick, point to buying pressure after a downtrend, while inverted hammers, with a long upper wick, suggest reversals after an uptrend. Arrows indicate identified patterns on the chart, signaling possible price changes. This tool aids traders in spotting reversals and complements various strategies by providing visual cue...
#MQL5 #MT5 #Indicator #Strategy

Read more...
👍2510🎉4👨‍💻21
Discover how the Connexus library streamlines HTTP requests in MetaTrader 5 with its innovative use of the Facade design pattern. The new CHttpRequest class acts as a simplified interface, integrating URL, header, body, and method components for seamless request creation. This approach not only simplifies code readability but also enhances maintainability and reduces coupling in complex systems. Additionally, CHttpResponse complements this by efficiently managing server response data. These enhancements provide MetaTrader 5 developers with a powerful toolset for algorithmic trading, offering clarity and ease in handling HTTP communications. Stay ahead in trading tech with Connexus' structured, accessible solutions.
#MQL5 #MT5 #HttpRequest #DesignPattern

Read more...
👍209👨‍💻31🔥1
To address challenges in analyzing trading history within MetaTrader 5, a mechanism is presented for efficient visualization of closed positions. This tackles the cluttered chart issue caused by numerous position labels. The aim is to streamline trading history analysis, enabling traders to focus on individual deals with enhanced understanding.

Functions will be developed to:
- Navigate closed positions using keyboard keys.
- Enhance tooltips with detailed deal information.
- Ensure key chart elements remain visible.

Understanding the creation of a position involves tracking trade orders and executed deals within netting or hedging account types. The historical position management requires constructing a list of closed positions from existing deals using a structured approach involving deal, position, and historical management classes.

The "Deal...
#MQL5 #MT5 #TradingTech #MetaTrader

Read more...
👍2216🔥4👨‍💻3🏆1
Developing a news-trading expert in MetaTrader 5 involves implementing stop orders to capitalize on market movements post-news events. The strategy focuses on managing slippage and ensuring trades open only when conditions are optimal. Stop orders are employed to capture breakouts by triggering trades at predefined price levels, minimizing the risk of market whipsaws. Classes like CAccountProperties and CSessions manage account limits and trading session timings, respectively. Efficient risk management further automates decision-making and safeguards against volatility, while careful session tracking avoids the pitfalls of overnight trading. These features offer traders and developers robust mechanisms for automating and optimizing news-related trading strategies.
#MQL5 #MT5 #Strategy #AlgoTrading

Read more...
👍3623👌6👨‍💻42
The LazyBear Squeeze Momentum Indicator, originally available on TradingView, is now converted to MQL4, allowing users to integrate this tool into their MetaTrader 4 platform. This technical indicator assists traders in identifying periods of squeezed volatility and potential price momentum shifts. The conversion retains the core logic of the original script, providing users with familiar analytical capabilities within a different trading environment. Deployment on MT4 now enables traders to use this volatility indicator alongside other dedicated forex tools, enhancing market analysis and decision-making processes within their custom trading strategies.
#MQL4 #MT4 #Indicator #AlgoTrading

Read more...
👍2815🔥3🏆3👨‍💻1
Effective portfolio risk management is crucial in today's complex investment environment. Analyzing asset allocations and managing risk becomes even more challenging as markets expand. A statistical approach, such as Principal Components Analysis (PCA), can be utilized to manage a portfolio's variance effectively.

PCA can assist in handling investments of volatile digital assets like cryptocurrencies. By applying PCA to cryptocurrency returns, it's possible to determine optimal trading strategies with varying risk levels. This method helps traders decide on asset positions and capital allocations, potentially leading to more informed decision-making.

Implementing these strategies in trading applications like MetaTrader 5 enhances risk management. The use of tools like PCA effectively supports trading application development, fostering smarter trad...
#MQL5 #MT5 #Portfolio #AlgoTrading

Read more...
19👍124👨‍💻21
Stepwise feature selection has been a traditional method in machine learning for optimizing variable subsets, but it often struggles with overfitting and interaction captures. This article introduces an advanced algorithm implemented in MQL5 that addresses these issues by exploring multiple promising feature combinations, using cross-validation to prevent overfitting, and integrating with various models. This method efficiently identifies powerful feature interactions without exhaustive searches, offering enhanced reliability for traders leveraging algorithmic strategies. It improves model robustness by focusing on statistical significance and adaptability, streamlining the feature selection process for more accurate predictions in complex data scenarios.
#MQL5 #MT5 #AI #ML

Read more...
👍2013👨‍💻43😁1
The Ichimoku Kinko Hyo, often known as the Ichimoku Cloud, is a robust technical analysis system offering insights into market trends, support and resistance levels, and momentum. Originating in Japan, it provides a holistic view using five lines: Tenkan-sen, Kijun-sen, Senkou Span A, Senkou Span B, and Chikou Span, each capturing distinct price behaviors.

Key patterns include the Tenkan-Sen and Kijun-Sen crossover, Kumo breakout, and Chikou span confirmation. While useful, each pattern has limitations such as susceptibility to market noise and delayed signals in volatile conditions. Optimal use involves understanding broader market contexts and Ichimoku elements, ensuring comprehensive analysis.
#MQL5 #MT5 #Ichimoku #AlgoTrading

Read more...
👍4322🏆11🎉6🔥3🤔3👨‍💻3
The code provides a basic framework where variable names are descriptive for ease of understanding. It includes functionality for toggling the Hull Method on or off. Additionally, raw values for speed and acceleration can be graphed. For experimentation, values can be plotted as absolute numbers to create a usable oscillator. It is suggested to use the square of the period (period*period) for the AVG_PERIOD to improve functionality. Note: A bug in the calculation cycles was corrected on September 6, 2022. While optimisation may be necessary, the structure and variable naming contribute to readability and enhance maintenance. Ensure that all implementations are validated for accuracy.
#MQL4 #MT4 #AlgoTrading #Oscillator

Read more...
👍2118👌52👨‍💻2