The updated ZigZag indicator now includes automatic step size determination for changing wave direction, eliminating complexity with only one configurable parameter: Scale. The default Scale setting is 1.0, providing a balanced sensitivity. Adjusting the Scale to 0.5 reduces sensitivity, leading to fewer zigzag wave reversals. Conversely, setting the Scale to 2.0 increases sensitivity, resulting in more frequent reversals. The step size for changing wave direction is dynamically determined by the price itself, allowing the user to define the Scale at which to identify zigzag extremes. This flexibility helps in adapting to various market conditions and enhances pattern recognition on price charts.
#MQL4 #MT4 #Indicator #Strategy
Read more...
#MQL4 #MT4 #Indicator #Strategy
Read more...
π41β€18π€―4π2π¨βπ»2π€1π1
In recent development of the TabControl WinForms object, a challenge was encountered with graphical element name length that limited the object creation process. The prior naming convention incorporated a full hierarchical reference in each child element's name, often exceeding the 63-character limit. A new naming methodology was implemented to resolve this by using the program name, element type, and an index indicating the number of similar elements already present.
This change allows unlimited nesting without exceeding name length restrictions. To further enhance clarity on the purpose and identification of elements, a new "description" property was introduced. This property provides a meaningful description, making it easier to reference these elements directly in the program.
In parallel, continued development of the TabControl included the crea...
#MQL5 #MT5 #Algorithm #WinForms
Read more...
This change allows unlimited nesting without exceeding name length restrictions. To further enhance clarity on the purpose and identification of elements, a new "description" property was introduced. This property provides a meaningful description, making it easier to reference these elements directly in the program.
In parallel, continued development of the TabControl included the crea...
#MQL5 #MT5 #Algorithm #WinForms
Read more...
π44β€14π9π¨βπ»7π4π2π2
The new update for the trading strategy Version 2 includes significant enhancements to risk management and signal control. Two new features, 'Stop Loss' and 'Take Profit', have been added for better regulation of trade exits. A 'Trailing Activate' parameter is introduced to improve stop-loss adjustments. Unlike 'Trailing Stop' or 'Trailing Step', 'Trailing Activate' acts as a breakeven function, securing profits as positions turn favorable. Once a position gains 'Trailing Activate' points, the stop loss shifts to this new level, allowing standard trailing functions to proceed.
Additionally, a new 'Time Control' parameter group is introduced to refine signal detection. This feature permits setting a specific time range using the 'Use Time Control' toggle, with start and end times down to the minute. This allows for precise signal searches across daily transi...
#MQL5 #MT5 #EA #Strategy
Read more...
Additionally, a new 'Time Control' parameter group is introduced to refine signal detection. This feature permits setting a specific time range using the 'Use Time Control' toggle, with start and end times down to the minute. This allows for precise signal searches across daily transi...
#MQL5 #MT5 #EA #Strategy
Read more...
π35β4π¨βπ»4β€2π1π1
The article focuses on designing a trading system using the Alligator indicator in MetaTrader 5 using MQL5. The Alligator, developed by Bill Williams, utilizes three smoothed moving averages known as the Jaw, Teeth, and Lips. These components help identify market trends, determining whether they are up, down, or sideways.
The piece outlines three strategies: Trend Identifier, Signals System, and Enhanced Signals System. Each strategy generates trading signals based on the position of Alligator lines.
Development of these systems involves implementing MQL5 code to automate signal generation. The code examples show how an EA can be configured to display market signals directly on the chart.
#MQL5 #MT5 #Trading #Indicator
Read more...
The piece outlines three strategies: Trend Identifier, Signals System, and Enhanced Signals System. Each strategy generates trading signals based on the position of Alligator lines.
Development of these systems involves implementing MQL5 code to automate signal generation. The code examples show how an EA can be configured to display market signals directly on the chart.
#MQL5 #MT5 #Trading #Indicator
Read more...
π52β€28π¨βπ»3π2β‘1
A new and straightforward indicator has been developed that plots a channel with a constant range, calculated as twice the step-size parameter. This range is violated when the lower quote price surpasses the channel's upper boundary or when the higher quote price falls below the lower boundary. The indicator is built using conditional compilation, ensuring compatibility with both MQL4 and MQL5. For those interested in accessing the source code, it's now available under "Public Projects" in the MetaEditor, labeled with the name "FMIC". Ensure to review and integrate as needed for your technical advancements.
#MQL5 #MT5 #Indicator #FMIC
Read more...
#MQL5 #MT5 #Indicator #FMIC
Read more...
β€28π14β9π6π6π¨βπ»1
Refine your MetaTrader 5 algorithmic trading library with improvements to graphical library classes that address mouse interaction issues and optimize color handling. The article discusses enhancements including new sorting properties for graphical elements and a restructured naming convention to prevent excessive name lengths that can lead to resource handling issues. It introduces the development of the TabControl WinForms object, outlining preparations for its full implementation. These adjustments cater to improved layout flexibility and performance, highlighting the significance of efficient UI interaction handling and clean system resource management, essential for both traders and developers refining their trading algorithms.
#MQL5 #MT5 #WinForms #GUI
Read more...
#MQL5 #MT5 #WinForms #GUI
Read more...
β€38π28π4β3π2β‘1π¨βπ»1
A practical example illustrates the implementation of profit and loss labels for the most recently closed trades in an Expert Advisor. This tool simulates dummy trades allowing observation within the strategy tester environment. The labels appear only on new trades, excluding historical data. This solution utilizes both the Canvas library and the standard library for implementation. Two configurable inputs offer a choice between employing the Canvas method versus text and rectangle objects from the standard library. Users are encouraged to refine or enhance the code as needed to explore alternative approaches or improvements that might better fit your strategic requirements.
#MQL5 #MT5 #EA #coding
Read more...
#MQL5 #MT5 #EA #coding
Read more...
π37β€14π4π3π¨βπ»3π―2π1
Recurrent neural networks (RNNs) offer distinct advantages for tasks involving temporal patterns, such as stock market predictions or video sequence analysis. Unlike traditional networks, RNNs can remember previous inputs, thus reducing redundant data processing and enhancing predictive accuracy. Each neuron in an RNN retains a state representing compressed input history. Through the use of activation functions with values less than one, the impact of older data diminishes gradually, yielding a predictable memory horizon. Integration of RNNs in tasks like video analysis or language translation has shown promising results, supporting both supervised and unsupervised learning frameworks effectively.
Implementing RNNs requires attention to architecture, especially when leveraging technologies such as OpenCL for performance optimization. With advancements like increa...
#MQL5 #MT5 #RNN #ML
Read more...
Implementing RNNs requires attention to architecture, especially when leveraging technologies such as OpenCL for performance optimization. With advancements like increa...
#MQL5 #MT5 #RNN #ML
Read more...
π48β€17β5π4π¨βπ»3π2π2
A straightforward channel indicator has been developed with a consistent range dictated by twice the step-size parameter. The indicator's range is breached when the low quote price surpasses the upper boundary or the high quote price exceeds the lower boundary. This code employs conditional compilation, allowing compatibility across both MQL4 and MQL5 platforms. Additionally, all related source code is now accessible in the "Public Projects" section of MetaEditor. The publication can be found under the name "FMIC" in CodeBase. This update ensures broader accessibility and utility for developers working with these platforms.
#MQL4 #MT4 #Indicator #Strategy
Read more...
#MQL4 #MT4 #Indicator #Strategy
Read more...
π31β€19π¨βπ»4β‘3π3β2π2
The article delves into innovative adaptations of the Commodity Channel Index (CCI) to improve its analytical accuracy and application in trading. By altering the calculation logic, such as replacing division with multiplication, and considering new statistical methods to set indicator levels, the modifications aim to produce unique and reliable indicator values. The evaluation is further enhanced by using diverse window functions like triangular and flat-top, resulting in varied outcomes. Testing with expert advisors reveals significant differences in trading performance. The adaptations provide traders customizability and potentially more informed trading decisions, catering to both classic and modern trading strategies.
#MQL5 #MT5 #CCI #EA
Read more...
#MQL5 #MT5 #CCI #EA
Read more...
β€44π22π5β‘4π3π¨βπ»2π1
A straightforward trend-following strategy is introduced for daily (D1) time frames. Buy signals trigger when the closing price crosses above the EMA based on high prices, provided the RSI is above 55. Sell signals occur when the closing price crosses below the EMA based on low prices, with RSI below 45. Any existing trade will close upon an opposing signal. This strategy includes take profit and stop loss mechanisms to manage risk effectively. Decision-making relies on the calculated EMA and RSI indicators to ensure adherence to the defined trading logic. Suitable for traders seeking structured approaches within daily time frames.
#MQL4 #MT4 #Strategy #Trend
Read more...
#MQL4 #MT4 #Strategy #Trend
Read more...
π37β€15π¨βπ»8π4β2π2π1
Variational Autoencoders Unveiled"
The variational autoencoder (VAE) offers advanced unsupervised learning capabilities. It differs from standard autoencoders by incorporating a probabilistic approach to output distributed representations instead of single deterministic values. This addresses the interpolation gap issue seen in traditional autoencoders when reconstructing image data.
The VAE architecture uses an encoder to output distributions characterized by mean and standard deviation instead of discrete values. The reparameterization trick is key, allowing backpropagation compatibility despite non-differentiable elements like random generation by sampling from a standard normal distribution, and adjusting with learned parameters.
Regularization via KullbackβLeibler divergence encourages feature distribution alignment to a standard normal distribution, balan...
#MQL5 #MT5 #AI #ML
Read more...
The variational autoencoder (VAE) offers advanced unsupervised learning capabilities. It differs from standard autoencoders by incorporating a probabilistic approach to output distributed representations instead of single deterministic values. This addresses the interpolation gap issue seen in traditional autoencoders when reconstructing image data.
The VAE architecture uses an encoder to output distributions characterized by mean and standard deviation instead of discrete values. The reparameterization trick is key, allowing backpropagation compatibility despite non-differentiable elements like random generation by sampling from a standard normal distribution, and adjusting with learned parameters.
Regularization via KullbackβLeibler divergence encourages feature distribution alignment to a standard normal distribution, balan...
#MQL5 #MT5 #AI #ML
Read more...
π44β€30β‘13π11π¨βπ»11πΎ8β4
This trading assistant is specifically designed for manual trading operations, operating exclusively on the current symbol. It utilizes a new parameter for trailing known as 'Trailing activate if profit is >= ', serving as a breakeven point for triggering the trailing mechanism. If a position reaches this set profit level, trailing will be activated. In instances where positions lack Stop Loss or Take Profit values, the assistant automatically applies the specified input parameters. Additionally, the assistant tracks target profits: once the target is reached, all positions are closed. Importantly, this Expert Advisor does not restrict the use of Magic numbers and ensures that, when modifying positions, the Magic number is preserved. This enhances flexibility and efficiency in managing trades effectively.
#MQL5 #MT5 #EA #Trading
Read more...
#MQL5 #MT5 #EA #Trading
Read more...
π25β€20π3π1π¨βπ»1
Creating a base class for WinForms object lists in your library enhances modularity and reusability. This class will encapsulate common functionalities needed for handling lists of WinForms objects, serving as a foundation for derived classes such as ListBox and ButtonListBox. By implementing this base object, you'll streamline future developments, ensuring a consistent structure and reducing redundancy.
Enhancements in library classes include making necessary adjustments in access controls for private methods to maintain functionality after recent client terminal updates. This involves refining inheritance and encapsulation practices to ensure seamless interaction with private methods through protected access.
The addition of new graphical element types and properties supports the comprehensive handling of UI elements. In the context of creating g...
#MQL5 #MT5 #WinForms #SoftwareDev
Read more...
Enhancements in library classes include making necessary adjustments in access controls for private methods to maintain functionality after recent client terminal updates. This involves refining inheritance and encapsulation practices to ensure seamless interaction with private methods through protected access.
The addition of new graphical element types and properties supports the comprehensive handling of UI elements. In the context of creating g...
#MQL5 #MT5 #WinForms #SoftwareDev
Read more...
β€46π27π¨βπ»10π4β‘1β1
Users involved in data collection for modeling can utilize time dummies as a tool in economic modeling. The provided indicator generates each hour of the day as a binary buffer array vector, with an additional buffer storing the specific hour. When collecting data from other indicators, such as via a CopyBuffer function, this tool can add dummy columns for hours to the dataset. Ideal for those compiling data for machine learning or similar purposes, it offers a straightforward dummy variable (buffers 0-23) and an hour variable (buffer 24) for modeling.
The process begins by declaring buffer and plot numbers as 25. Buffer labels are assigned within the data window, followed by the declaration of buffers and an integer variable for the current hour. Using SetIndexBuffer proved challenging during looping, leading to an alternative approach, although plotting i...
#MQL5 #MT5 #Indicator #ML
Read more...
The process begins by declaring buffer and plot numbers as 25. Buffer labels are assigned within the data window, followed by the declaration of buffers and an integer variable for the current hour. Using SetIndexBuffer proved challenging during looping, leading to an alternative approach, although plotting i...
#MQL5 #MT5 #Indicator #ML
Read more...
β€30π22β‘3π¨βπ»2π1π1π1
Polynomial regression serves as a key method in machine learning for handling nonlinear data relationships. It extends the capabilities of basic linear regression by fitting a polynomial equation to the data, allowing for more flexibility in modeling. Determining the optimal polynomial order plays a crucial role, which can be evaluated using criteria such as the Bayesian Information Criterion (BIC).
The process of finding coefficients involves matrix operations, making tools like matrix inversion fundamental. Feature scaling is essential to prevent large ranges from impacting the polynomial's power computations. However, caution is advised due to potential overfitting, which compromises performance on out-of-sample data. It remains vital to validate models with diverse datasets to assess generalization properties effectively.
#MQL5 #MT5 #ML #PolyReg
Read more...
The process of finding coefficients involves matrix operations, making tools like matrix inversion fundamental. Feature scaling is essential to prevent large ranges from impacting the polynomial's power computations. However, caution is advised due to potential overfitting, which compromises performance on out-of-sample data. It remains vital to validate models with diverse datasets to assess generalization properties effectively.
#MQL5 #MT5 #ML #PolyReg
Read more...
β€33π25π6π2π¨βπ»2
This code snippet is designed for implementing a trailing stop loss in your Expert Advisor (EA) on MQL5. It provides a framework that automatically adjusts the stop loss level as the trade moves in a favorable direction. The essential variables include `Lot`, `Setloss`, `TakeProfit`, and `TslPoints`.
You need to initialize the `CTrade`, `COrderInfo`, and `CPositionInfo` objects for managing trades and accessing position information. Parameters such as `InpMagic` allow you to specify a unique identifier for the trades so that the EA manages the intended orders.
Place the main logic within the `OnTick` function, calling the `TrailStop` method to check open positions and adjust the stop loss dynamically based on the market movements. This snippet supports both buy and sell positions, ensuring that the trailing stop activates only after the profit exc...
#MQL5 #MT5 #AlgoTrading #Strategy
Read more...
You need to initialize the `CTrade`, `COrderInfo`, and `CPositionInfo` objects for managing trades and accessing position information. Parameters such as `InpMagic` allow you to specify a unique identifier for the trades so that the EA manages the intended orders.
Place the main logic within the `OnTick` function, calling the `TrailStop` method to check open positions and adjust the stop loss dynamically based on the market movements. This snippet supports both buy and sell positions, ensuring that the trailing stop activates only after the profit exc...
#MQL5 #MT5 #AlgoTrading #Strategy
Read more...
π41β€20β‘2π¨βπ»2π2π1
The article focuses on enhancing neural network models for trading applications. It utilizes MetaTrader 5, emphasizing its compatibility without third-party software. Initially, a basic perceptron example is introduced, evolving to more complex networks using the MQL library. The main structure proposed is a 4-4-3 network requiring 35 weights and biases, followed by the development of multiple Expert Advisors (EAs).
Optimization challenges are addressed using random number generation for parameter settings. The article discusses CSV files for storing optimization results and emphasizes an efficient method for EA tuning by employing a novel optimization algorithm. Testing was conducted across various timelines, resulting in better performance for the Angle EA compared to the Figure EA.
Future work involves optimization over larger periods and explo...
#MQL5 #MT5 #NeuralNet #AlgoTrading
Read more...
Optimization challenges are addressed using random number generation for parameter settings. The article discusses CSV files for storing optimization results and emphasizes an efficient method for EA tuning by employing a novel optimization algorithm. Testing was conducted across various timelines, resulting in better performance for the Angle EA compared to the Figure EA.
Future work involves optimization over larger periods and explo...
#MQL5 #MT5 #NeuralNet #AlgoTrading
Read more...
π53β€29π€4π4π¨βπ»3β‘1
A new parameter for trailing, 'Trailing activate if profit is >=', functions as a breakeven trigger for trailing operations. Trailing is initiated only after a position reaches a specific profit level, defined in 'Trailing activate if profit is >='. The Expert Advisor is designed to operate on the current trading symbol and adapts to any Magic number for seamless position modification. This feature enhances trading strategy by enabling more precise control over trailing stop adjustments based on predefined profit thresholds, ensuring more efficient risk management. The system does not limit functionality to specific Magic numbers, allowing greater flexibility in trade management.
#MQL5 #MT5 #EA #Strategy
Read more...
#MQL5 #MT5 #EA #Strategy
Read more...
π35β€18π¨βπ»5π2β‘1π1
In the previous segment of this resource, the focus was on optimizing the mechanism for adjusting pending orders and stop levels in a trading system. This approach, while aligning closely with server-side conditions, faced latency issues due to server communication on each tick adjustment. The solution proposed involves bypassing intermediary values, enabling a more responsive method of updating levels.
Implementation involves creating a 'ghost' label, an invisible indicator reflecting real-time changes, and making adjustments in the C_IndicatorTradeView class. This technique allows on-chart comparison without disrupting the system.
Changes in the variable handling within DispatchMessage and the introduction of a shared class variable help delineate the ghost from the real label, ensuring smooth operation.
These adjustments aim to streamline the process o...
#MQL5 #MT5 #EA #Indicator
Read more...
Implementation involves creating a 'ghost' label, an invisible indicator reflecting real-time changes, and making adjustments in the C_IndicatorTradeView class. This technique allows on-chart comparison without disrupting the system.
Changes in the variable handling within DispatchMessage and the introduction of a shared class variable help delineate the ghost from the real label, ensuring smooth operation.
These adjustments aim to streamline the process o...
#MQL5 #MT5 #EA #Indicator
Read more...
π54β€19π¨βπ»4π±2