![Developing a Replay System (Part 31): Expert Advisor project — C_Mouse class (V)](https://c.mql5.com/2/59/sistema_de_Replay_up_600x314.jpg)
Developing a Replay System (Part 31): Expert Advisor project — C_Mouse class (V)
We need a timer that can show how much time is left till the end of the replay/simulation run. This may seem at first glance to be a simple and quick solution. Many simply try to adapt and use the same system that the trading server uses. But there's one thing that many people don't consider when thinking about this solution: with replay, and even m ore with simulation, the clock works differently. All this complicates the creation of such a system.
![Developing a quality factor for Expert Advisors](https://c.mql5.com/2/55/Desenvolvendo_um_fator_de_qualidade_para_os_EAs_600x314.jpg)
Developing a quality factor for Expert Advisors
In this article, we will see how to develop a quality score that your Expert Advisor can display in the strategy tester. We will look at two well-known calculation methods – Van Tharp and Sunny Harris.
![Modified Grid-Hedge EA in MQL5 (Part IV): Optimizing Simple Grid Strategy (I)](https://c.mql5.com/2/79/Modified_Grid-Hedge_EA_in_MQL5_Part_III_600x314__1.jpg)
Modified Grid-Hedge EA in MQL5 (Part IV): Optimizing Simple Grid Strategy (I)
In this fourth part, we revisit the Simple Hedge and Simple Grid Expert Advisors (EAs) developed earlier. Our focus shifts to refining the Simple Grid EA through mathematical analysis and a brute force approach, aiming for optimal strategy usage. This article delves deep into the mathematical optimization of the strategy, setting the stage for future exploration of coding-based optimization in later installments.
![The case for using a Composite Data Set this Q4 in weighing SPDR XLY's next performance](https://c.mql5.com/2/61/Composite_Data_Set_this_Q4_in_weighing_SPDR_XLY_600x314.jpg)
The case for using a Composite Data Set this Q4 in weighing SPDR XLY's next performance
We consider XLY, SPDR’s consumer discretionary spending ETF and see if with tools in MetaTrader’s IDE we can sift through an array of data sets in selecting what could work with a forecasting model with a forward outlook of not more than a year.
![Neural networks made easy (Part 41): Hierarchical models](https://c.mql5.com/2/54/NN_Simple_Part_41_Hierarchical_Models_600x314.jpg)
Neural networks made easy (Part 41): Hierarchical models
The article describes hierarchical training models that offer an effective approach to solving complex machine learning problems. Hierarchical models consist of several levels, each of which is responsible for different aspects of the task.
![Developing a multi-currency Expert Advisor (Part 2): Transition to virtual positions of trading strategies](https://c.mql5.com/2/69/Developing_a_multi-currency_advisor_5Part_2f_Transition_to_virtual_positions_of_trading_strategies_6.jpg)
Developing a multi-currency Expert Advisor (Part 2): Transition to virtual positions of trading strategies
Let's continue developing a multi-currency EA with several strategies working in parallel. Let's try to move all the work associated with opening market positions from the strategy level to the level of the EA managing the strategies. The strategies themselves will trade only virtually, without opening market positions.
![Neural networks made easy (Part 61): Optimism issue in offline reinforcement learning](https://c.mql5.com/2/59/NN_easy_61_SPLT_V2__600x314.jpg)
Neural networks made easy (Part 61): Optimism issue in offline reinforcement learning
During the offline learning, we optimize the Agent's policy based on the training sample data. The resulting strategy gives the Agent confidence in its actions. However, such optimism is not always justified and can cause increased risks during the model operation. Today we will look at one of the methods to reduce these risks.
![MQL5 Wizard Techniques you should know (Part 07): Dendrograms](https://c.mql5.com/2/59/Dendrograms_600x314.jpg)
MQL5 Wizard Techniques you should know (Part 07): Dendrograms
Data classification for purposes of analysis and forecasting is a very diverse arena within machine learning and it features a large number of approaches and methods. This piece looks at one such approach, namely Agglomerative Hierarchical Classification.
![Cross-validation and basics of causal inference in CatBoost models, export to ONNX format](https://c.mql5.com/2/60/CatBoost_export_to_ONNX_format_600x314.jpg)
Cross-validation and basics of causal inference in CatBoost models, export to ONNX format
The article proposes the method of creating bots using machine learning.
![Category Theory in MQL5 (Part 17): Functors and Monoids](https://c.mql5.com/2/57/Category-Theory-p17_600x314.jpg)
Category Theory in MQL5 (Part 17): Functors and Monoids
This article, the final in our series to tackle functors as a subject, revisits monoids as a category. Monoids which we have already introduced in these series are used here to aid in position sizing, together with multi-layer perceptrons.
![Creating a market making algorithm in MQL5](https://c.mql5.com/2/64/Creating_a_market_making_algorithm_in_MQL5_600x314.jpg)
Creating a market making algorithm in MQL5
How do market makers work? Let's consider this issue and create a primitive market-making algorithm.
![Developing a Replay System (Part 29): Expert Advisor project — C_Mouse class (III)](https://c.mql5.com/2/58/replay-p28_600x314.jpg)
Developing a Replay System (Part 29): Expert Advisor project — C_Mouse class (III)
After improving the C_Mouse class, we can focus on creating a class designed to create a completely new framework fr our analysis. We will not use inheritance or polymorphism to create this new class. Instead, we will change, or better said, add new objects to the price line. That's what we will do in this article. In the next one, we will look at how to change the analysis. All this will be done without changing the code of the C_Mouse class. Well, actually, it would be easier to achieve this using inheritance or polymorphism. However, there are other methods to achieve the same result.
![Modified Grid-Hedge EA in MQL5 (Part III): Optimizing Simple Hedge Strategy (I)](https://c.mql5.com/2/72/Modified_Grid-Hedge_EA_in_MQL5_Part_III_600x314.jpg)
Modified Grid-Hedge EA in MQL5 (Part III): Optimizing Simple Hedge Strategy (I)
In this third part, we revisit the Simple Hedge and Simple Grid Expert Advisors (EAs) developed earlier. Our focus shifts to refining the Simple Hedge EA through mathematical analysis and a brute force approach, aiming for optimal strategy usage. This article delves deep into the mathematical optimization of the strategy, setting the stage for future exploration of coding-based optimization in later installments.
![Neural networks are easy (Part 59): Dichotomy of Control (DoC)](https://c.mql5.com/2/59/Caregory_600x314.jpg)
Neural networks are easy (Part 59): Dichotomy of Control (DoC)
In the previous article, we got acquainted with the Decision Transformer. But the complex stochastic environment of the foreign exchange market did not allow us to fully implement the potential of the presented method. In this article, I will introduce an algorithm that is aimed at improving the performance of algorithms in stochastic environments.
![Neural networks made easy (Part 72): Trajectory prediction in noisy environments](https://c.mql5.com/2/64/Neural_networks_made_easy_ePart_726_Predicting_trajectories_in_the_presence_of_noise_600x314.jpg)
Neural networks made easy (Part 72): Trajectory prediction in noisy environments
The quality of future state predictions plays an important role in the Goal-Conditioned Predictive Coding method, which we discussed in the previous article. In this article I want to introduce you to an algorithm that can significantly improve the prediction quality in stochastic environments, such as financial markets.
![MQL5 Wizard Techniques you should know (Part 12): Newton Polynomial](https://c.mql5.com/2/70/MQL5_Wizard_Techniques_you_should_know_Part_12_Newton_Polynomial_600x314.jpg)
MQL5 Wizard Techniques you should know (Part 12): Newton Polynomial
Newton’s polynomial, which creates quadratic equations from a set of a few points, is an archaic but interesting approach at looking at a time series. In this article we try to explore what aspects could be of use to traders from this approach as well as address its limitations.
![Data label for time series mining (Part 6):Apply and Test in EA Using ONNX](https://c.mql5.com/2/64/Data_label_for_time_series_mining_wPart_6v_Apply_and_Test_in_EA_Using_ONNX_600x314.jpg)
Data label for time series mining (Part 6):Apply and Test in EA Using ONNX
This series of articles introduces several time series labeling methods, which can create data that meets most artificial intelligence models, and targeted data labeling according to needs can make the trained artificial intelligence model more in line with the expected design, improve the accuracy of our model, and even help the model make a qualitative leap!
![Combinatorially Symmetric Cross Validation In MQL5](https://c.mql5.com/2/60/Combinatorially_Symmetric_Cross_Validation_600x314.jpg)
Combinatorially Symmetric Cross Validation In MQL5
In this article we present the implementation of Combinatorially Symmetric Cross Validation in pure MQL5, to measure the degree to which a overfitting may occure after optimizing a strategy using the slow complete algorithm of the Strategy Tester.
![Introduction to MQL5 (Part 5): A Beginner's Guide to Array Functions in MQL5](https://c.mql5.com/2/73/Introduction_to_MQL5_Part_5_600x314.jpg)
Introduction to MQL5 (Part 5): A Beginner's Guide to Array Functions in MQL5
Explore the world of MQL5 arrays in Part 5, designed for absolute beginners. Simplifying complex coding concepts, this article focuses on clarity and inclusivity. Join our community of learners, where questions are embraced, and knowledge is shared!
![Developing a Replay System (Part 30): Expert Advisor project — C_Mouse class (IV)](https://c.mql5.com/2/58/replay-p30_600x314.jpg)
Developing a Replay System (Part 30): Expert Advisor project — C_Mouse class (IV)
Today we will learn a technique that can help us a lot in different stages of our professional life as a programmer. Often it is not the platform itself that is limited, but the knowledge of the person who talks about the limitations. This article will tell you that with common sense and creativity you can make the MetaTrader 5 platform much more interesting and versatile without resorting to creating crazy programs or anything like that, and create simple yet safe and reliable code. We will use our creativity to modify existing code without deleting or adding a single line to the source code.
![Neural networks made easy (Part 63): Unsupervised Pretraining for Decision Transformer (PDT)](https://c.mql5.com/2/60/Neural_networks_are_easy_aPart_63n_600x314.jpg)
Neural networks made easy (Part 63): Unsupervised Pretraining for Decision Transformer (PDT)
We continue to discuss the family of Decision Transformer methods. From previous article, we have already noticed that training the transformer underlying the architecture of these methods is a rather complex task and requires a large labeled dataset for training. In this article we will look at an algorithm for using unlabeled trajectories for preliminary model training.
![MQL5 Wizard Techniques You Should Know (Part 15): Support Vector Machines with Newton's Polynomial](https://c.mql5.com/2/75/MQL5_Wizard_Techniques_You_Should_Know_wPart_15y_600x314.jpg)
MQL5 Wizard Techniques You Should Know (Part 15): Support Vector Machines with Newton's Polynomial
Support Vector Machines classify data based on predefined classes by exploring the effects of increasing its dimensionality. It is a supervised learning method that is fairly complex given its potential to deal with multi-dimensioned data. For this article we consider how it’s very basic implementation of 2-dimensioned data can be done more efficiently with Newton’s Polynomial when classifying price-action.
![MQL5 Wizard Techniques you should know (Part 22): Conditional GANs](https://c.mql5.com/2/80/MQL5_Wizard_Techniques_you_should_know_Part_22_600x314.jpg)
MQL5 Wizard Techniques you should know (Part 22): Conditional GANs
Generative Adversarial Networks are a pairing of Neural Networks that train off of each other for more accurate results. We adopt the conditional type of these networks as we look to possible application in forecasting Financial time series within an Expert Signal Class.
![MQL5 Wizard Techniques you should know (Part 10). The Unconventional RBM](https://c.mql5.com/2/64/MQL5_Wizard_Techniques_you_should_know_6Part_10i_The_Unconventional_RBM_600x314.jpg)
MQL5 Wizard Techniques you should know (Part 10). The Unconventional RBM
Restrictive Boltzmann Machines are at the basic level, a two-layer neural network that is proficient at unsupervised classification through dimensionality reduction. We take its basic principles and examine if we were to re-design and train it unorthodoxly, we could get a useful signal filter.
![Population optimization algorithms: Artificial Multi-Social Search Objects (MSO)](https://c.mql5.com/2/69/Population_optimization_algorithms___Artificial_Multi-Social_Search_Objects_zMSO4_600x314.jpg)
Population optimization algorithms: Artificial Multi-Social Search Objects (MSO)
This is a continuation of the previous article considering the idea of social groups. The article explores the evolution of social groups using movement and memory algorithms. The results will help to understand the evolution of social systems and apply them in optimization and search for solutions.
![Data label for time series mining (Part 5):Apply and Test in EA Using Socket](https://c.mql5.com/2/64/Data_label_for_time_series_miningcPart_5c_Apply_and_Test_in_EA_Using_Socket_600x314.jpg)
Data label for time series mining (Part 5):Apply and Test in EA Using Socket
This series of articles introduces several time series labeling methods, which can create data that meets most artificial intelligence models, and targeted data labeling according to needs can make the trained artificial intelligence model more in line with the expected design, improve the accuracy of our model, and even help the model make a qualitative leap!
![Integrate Your Own LLM into EA (Part 3): Training Your Own LLM with CPU](https://c.mql5.com/2/79/Integrate_Your_Own_LLM_into_EA__Part_3_-_Training_Your_Own_LLM_with_CPU_600x314.jpg)
Integrate Your Own LLM into EA (Part 3): Training Your Own LLM with CPU
With the rapid development of artificial intelligence today, language models (LLMs) are an important part of artificial intelligence, so we should think about how to integrate powerful LLMs into our algorithmic trading. For most people, it is difficult to fine-tune these powerful models according to their needs, deploy them locally, and then apply them to algorithmic trading. This series of articles will take a step-by-step approach to achieve this goal.
![MQL5 Wizard Techniques you should know (Part 20): Symbolic Regression](https://c.mql5.com/2/78/MQL5_Wizard_Techniques_you_should_know_mPart_20b_600x314.jpg)
MQL5 Wizard Techniques you should know (Part 20): Symbolic Regression
Symbolic Regression is a form of regression that starts with minimal to no assumptions on what the underlying model that maps the sets of data under study would look like. Even though it can be implemented by Bayesian Methods or Neural Networks, we look at how an implementation with Genetic Algorithms can help customize an expert signal class usable in the MQL5 wizard.
![A Generic Optimization Formulation (GOF) to Implement Custom Max with Constraints](https://c.mql5.com/2/76/A_Generic_Optimization_Formulation_rGOF2_to_Implement_Custom_Max_with_Constraints_600x314.jpg)
A Generic Optimization Formulation (GOF) to Implement Custom Max with Constraints
In this article we will present a way to implement optimization problems with multiple objectives and constraints when selecting "Custom Max" in the Setting tab of the MetaTrader 5 terminal. As an example, the optimization problem could be: Maximize Profit Factor, Net Profit, and Recovery Factor, such that the Draw Down is less than 10%, the number of consecutive losses is less than 5, and the number of trades per week is more than 5.
![Neural networks made easy (Part 70): Closed-Form Policy Improvement Operators (CFPI)](https://c.mql5.com/2/63/Neural_Networks_Made_Easy_0Part_70g_CFPI_600x314.jpg)
Neural networks made easy (Part 70): Closed-Form Policy Improvement Operators (CFPI)
In this article, we will get acquainted with an algorithm that uses closed-form policy improvement operators to optimize Agent actions in offline mode.
![Neural networks made easy (Part 69): Density-based support constraint for the behavioral policy (SPOT)](https://c.mql5.com/2/63/Upscales.ai_1703440115554_600x314.jpg)
Neural networks made easy (Part 69): Density-based support constraint for the behavioral policy (SPOT)
In offline learning, we use a fixed dataset, which limits the coverage of environmental diversity. During the learning process, our Agent can generate actions beyond this dataset. If there is no feedback from the environment, how can we be sure that the assessments of such actions are correct? Maintaining the Agent's policy within the training dataset becomes an important aspect to ensure the reliability of training. This is what we will talk about in this article.
![Reimagining Classic Strategies: Crude Oil](https://c.mql5.com/2/79/Reimagining_Classic_Strategies____Crude_Oil_600x314.jpg)
Reimagining Classic Strategies: Crude Oil
In this article, we revisit a classic crude oil trading strategy with the aim of enhancing it by leveraging supervised machine learning algorithms. We will construct a least-squares model to predict future Brent crude oil prices based on the spread between Brent and WTI crude oil prices. Our goal is to identify a leading indicator of future changes in Brent prices.
![Gain An Edge Over Any Market (Part II): Forecasting Technical Indicators](https://c.mql5.com/2/80/Gain_An_Edge_Over_Any_Market_Part_II_600x314.jpg)
Gain An Edge Over Any Market (Part II): Forecasting Technical Indicators
Did you know that we can gain more accuracy forecasting certain technical indicators than predicting the underlying price of a traded symbol? Join us to explore how to leverage this insight for better trading strategies.
![Neural networks made easy (Part 69): Density-based support constraint for the behavioral policy (SPOT)](https://c.mql5.com/2/63/Upscales.ai_1703440115554_600x314.jpg)
Neural networks made easy (Part 69): Density-based support constraint for the behavioral policy (SPOT)
In offline learning, we use a fixed dataset, which limits the coverage of environmental diversity. During the learning process, our Agent can generate actions beyond this dataset. If there is no feedback from the environment, how can we be sure that the assessments of such actions are correct? Maintaining the Agent's policy within the training dataset becomes an important aspect to ensure the reliability of training. This is what we will talk about in this article.
![A Step-by-Step Guide on Trading the Break of Structure (BoS) Strategy](https://c.mql5.com/2/80/A_Step-by-Step_Guide_on_Trading_the_Break_of_Structure__600x314.jpg)
A Step-by-Step Guide on Trading the Break of Structure (BoS) Strategy
A comprehensive guide to developing an automated trading algorithm based on the Break of Structure (BoS) strategy. Detailed information on all aspects of creating an advisor in MQL5 and testing it in MetaTrader 5 — from analyzing price support and resistance to risk management
![MQL5 Trading Toolkit (Part 1): Developing A Positions Management EX5 Library](https://c.mql5.com/2/80/MQL5_Trading_Toolkit_Part_1_600x314.jpg)
MQL5 Trading Toolkit (Part 1): Developing A Positions Management EX5 Library
Learn how to create a developer's toolkit for managing various position operations with MQL5. In this article, I will demonstrate how to create a library of functions (ex5) that will perform simple to advanced position management operations, including automatic handling and reporting of the different errors that arise when dealing with position management tasks with MQL5.
![Developing a multi-currency Expert Advisor (Part 3): Architecture revision](https://c.mql5.com/2/70/Developing_a_multi-currency_advisor_6Part_3q__Architecture_review_600x314.jpg)
Developing a multi-currency Expert Advisor (Part 3): Architecture revision
We have already made some progress in developing a multi-currency EA with several strategies working in parallel. Considering the accumulated experience, let's review the architecture of our solution and try to improve it before we go too far ahead.
![Neural networks made easy (Part 74): Trajectory prediction with adaptation](https://c.mql5.com/2/65/Neural_networks_are_easy_4Part_74n_Adaptive_trajectory_prediction_600x314.jpg)
Neural networks made easy (Part 74): Trajectory prediction with adaptation
This article introduces a fairly effective method of multi-agent trajectory forecasting, which is able to adapt to various environmental conditions.