MQL5 Algo Trading
390K subscribers
2.58K photos
2.58K 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
Developers, ever had difficulty examining intricate patterns amid variations on crucial price charts? Fear not, as there's a seamless solution to detect elements that occur on the chart, such as price patterns. Often, trend or chart patterns can be predicted by meticulous observation and targeted tools.

This article talks about using MQL5 (MetaQuotes Language) IDE built into the MetaTrader 5 trading terminal. By creating tailored tools using MQL5, it's possible to identify critical chart patterns such as highs and lows, trends, double tops, and double bottoms.

For example, Highs and Lows on a chart can be detected by creating a function out of the OnTick() scope to return specific price levels (high and low). Further, trends can be detected by using the previously identified highs and lows. These trends or movements are classified into three: uptrends, downtrends, and sideways.

Fur...

Read more...
πŸ‘6πŸ‘3✍1
In the arena of evolving financial market analysis methods, the utilization of algorithmic and technical indicators has evolved significantly. Among them, the "Elder Impulse System Candlestick" deserves mention. This unique indicator offers color-coded visualization on the candlestick chart in accordance with the precepts of the Elder Impulse System.

Originating from the concepts formulated by Dr. Alexander Elder, this system amalgamates market momentum and trend observations into one comprehensive analysis tool. It is beneficial particularly for those engaged in high-speed trading, by providing an expedited visualization of market trends.

The Elder Impulse System Candlestick, by painting the patterns as per the system, explicates the complex numerical trends in an easily comprehensible, visually graphic form. This graphical representation accelerates decision-making potential of t...

Read more...
πŸ‘11
In the quest for stable trading, diversifying the traded instruments, strategies, and machine learning models are beneficial. Combining the various ONNX models trained in an MQL5 program can be challenging but rewarding. An ensemble titled 'voting classifier' underlines this concept efficiently.

The project includes two simple models. The first one is a regression model for predicting prices; it trains on EURUSD D1 data from 2003 to the end of 2022. To enhance its trainability, price normalization and division of the average price in the series by the standard deviation are performed.

The second model introduces a classification one, trained similarly but with a focus on predicting the class of price movements. The model defines one of three classes at its output: price declination, stability within 10 points, or an upward move.

A brief instance of an Expert Advisor for demonstrat...

Read more...
πŸ‘8πŸ‘3πŸ†1
A new indicator banner is available, designed with utmost simplicity to display Symbol Spread Equity Profit. This practical tool offers the convenience of monitoring equity without the need to open the terminal panel. It also aids in visualizing the optimal spread for symbol trade entry.

This indicator has been in regular use and has proven practical enough that decision was made to make it available for wider use. This initiative lines up with the commitment of providing tools that aid smoother trading operations.

Additionally, this software comes with a clear copyright and version information. Link for authentic details and latest updates has been provided for easy access.

Despite its efficacy, the software does have a mandatory disclaimer: users are to deploy this software at their own discretion. Losses or damages, or indeed any consequences arising out of its use are solely ...

Read more...
πŸ‘10😁2
Contemplating the significance of various cone setups in category theory and their implications for data analysis? The aim here is to provide a sensitivity analysis rather than a fresh concept for forecasting or market insights. Coequalizers and equalizers indicate the disparity or similarity within domain elements respectively. This distinction becomes paramount when configuring position sizing based on certain trading overlaps.

Category theory's universal application comes in handy for adjusting position sizing based on live drawdown readings. This post further discusses Monomorphic Pull-Backs which is largely a composition of domains that correlate over a given period. Surprisingly, the correlation between geometric mean value and the actual value does not always yield accurate projections. The post details how such anomalies can be addressed.

Explorations into epimorphic push-...

Read more...
πŸ‘7πŸ‘2πŸ‘Œ1
Engage in a comprehensive understanding of a new script focused on setting pending hedges with distance in pips for chart symbols. If 100% harmony is achieved in hedges, the strategy refrains from taking any step. On the contrary, it carries out calculations determining the difference between buy and sell trades and, subsequently, places a harmoniously pending hedge of 100%.

The strategy also exhibits an efficient method of deleting old hedges related to the symbol, paving the way for new ones. Hence, it is quite effective as a manual tool for trailing pending hedges when demanded.

This approach presents immense possibilities and opportunities for users in handling their trades strategically. Therefore, it is beneficial for users to familiarize themselves with this process, amplifying trading skills and possibilities. At the end of the day, optimizing all available tools and strateg...

Read more...
πŸ‘10πŸ‘3πŸ‘Œ1
The MQTT - a message-sharing protocol based on the publish/subscribe interaction model - proves to be valuable in trading environments due to its capacity to disseminate real-time data across various formats. Its resilience against network issues and content neutrality makes it a staple for connecting devices in the Internet of Things. The protocol is universally applicable in situations demanding real-time data-sharing among decoupled machines.

MQTT brokers are available for different environments, and clients can be accessed from any modern programming language. The code for this client development is majorly outlined with the Object-Oriented paradigm as its base.

Broker-type mediation is the primary distinguishing feature of MQTT protocol: it can incorporate many device instances and symbols, providing a solution for potential discrepancies where traders may have legitimate dat...

Read more...
πŸ‘2🀝2❀1πŸ‘1
Understanding the mechanics of Support Vector Machines (SVM), a machine learning classification algorithm, is vital for anyone interested in data science. Unlike clustering which identifies data groups organically, SVM separates data into predefined sets under supervision. The power of SVM lies in its ability to classify datasets with multiple dimensions, particularly when the data distribution is skewed.

One major drawback of SVM is its reliability with high dimensioned data due to a propensity towards overfitting the training data. Lower dimensioned data, however, cross-validates better making it more widely applicable. SVM implementation can be complex when dealing with multiple dimensions, with python or C# typically employing libraries to assist in coding.

Luckily, to simplify understanding, we'll look at a basic linear-SVM that handles 2-dimensional data. Rather than using t...

Read more...
πŸ‘7πŸ‘4
Understanding key mathematical concepts is critical for successful programming. One such imperative principle is the "Harmonic Mean". This numerical average is computed by the division of the total number of observations with the reciprocal of each respective figure in the series. It's noteworthy to state that the harmonic mean in itself is the reciprocal of the arithmetic mean of the reciprocals. It might sound complex, but once comprehended, it's a seamless tool in data structuring and manipulation.

Every budding and seasoned software developer should accustom themselves with this statistical tool as it's prevalent in algorithm efficiency evaluation and optimizing data query performances. Set a deliberate timer to study this fascinating concept to boost your software development expertise.

Read more...
πŸ‘7❀3πŸ‘2
Over the years, neural networks, particularly those using 'supervised learning' methods like backpropagation neural networks (BPNN), have become essential tools for traders. Various modifications of such algorithms form the base for deep, recurrent, and convolutional neural networks. Let's take a moment to appreciate the recent introduction of new API features on the MQL5 platform designed for matrix and vector operations. These new functions permit batch computations in neural networks, where data processing happens in blocks rather than element by element. The use of matrix operations noticeably streamlines program instructions, converting complex operations into single-line expressions.

Delving deeper, it's worth noting that neural networks are typically comprised of simple computing elementsβ€”neuronsβ€”grouped into layers and interconnected through synapses. The current state of a n...

Read more...
πŸ‘4
The application of a code block involves proficient use of a Stop Loss or its absence. The key facilitator is "Trade.mqh", a requisite for the CTrade class access. This class manages the interactions with positions and orders. Creating adjustable trailing distance invokes an input parameter, although not mandatory, it enhances convenience.

CTrade class needs an instance definition, with a non-specific naming convenience, and should be ideally set after the OnInt event handler. Validation for the presence of a running position initiates with an 'if' statement, further invoking the 'Check_TrailingStop()' function, applicable to each tick. This ensures an accurate and smooth trailing system.

Priority of the statement is highest at the commencement of the 'OnTick' event handler, ensuring optimal functionality. 'Check_TrailingStop()' is a user-centric function name that can be altered ...

Read more...
πŸ‘3❀1πŸ‘1
The code block provided facilitates a dynamic detection system for a new bar or candle upon receipt. Functioning on a simple principle, its initial action stores the time of the preceding bar or candle, followed by an addition of sixty seconds to that time. This results in a closing time value for the current bar or candle. Once the current time equals this newly calculated closing time, it signifies receipt of a new symbol or closure of the existing one.

An integral part of this code is the flag - a Boolean variable dubbed 'NewBarReceived'. This smartly prevents multiple calls to this block of code, ensuring its execution is limited to once per bar or candle. Comment(); alongside playsound("ok.wav"); act as tools to verify the code block's accuracy. These can be removed based on user preference.

A reset of the flag to a false state occurs once current Time surpasses the closing tim...

Read more...
πŸ‘4πŸ‘2❀1
Logarithmic Mean is a mathematical concept used for describing two non-negative values. In this equation, the disparity between two numbers is divided by the log of their quotient. This computation has valuable applications, notably in the field of engineering. It plays a pivotal role in resolving complex problems related to heat and mass transfer. Such a functional tool could be implemented as is, or could be refined further per the requirement of the task at hand. Remember, mathematics often provides the basis to navigate through intricate engineering conundrums and it's essential in various tech-oriented tasks and projects as well.

Read more...
πŸ‘2πŸ‘2❀1
Recently, the development team rolled out version 3 updates of the script. A new modification in this version allows the system to return a string that indicates whether the pip difference has gone up, stayed the same, or declined. One key feature of this version is that it now prints the price at the start and the end of each calculation.

Furthermore, it accurately calculates and displays the pip difference. The pip difference is computed as the difference between the prices during the commencement and the conclusion of the calculation. It is then converted into pips for comprehensive understanding.

One of the major enhancements added in this update is the direction of the pip difference. It can now indicate and print out the direction of the pip, providing more information for data analysis.

Version 3 also introduces a Point to Pip conversion factor. This function is added for s...

Read more...
πŸ‘3πŸ‘3
Reflecting the gravitational behavior of universal bodies, the Gravitational Search Algorithm (GSA) has been developed as a powerful tool to tackle optimization problems. Mirroring principles of Newton's law of gravitation, the algorithm uses an innovative approach dealing with particles as significant objects, creating a bridge between global physics and computational mathematics.

The algorithm highlights a massive natural force: gravity. While it is the weakest among all four fundamental forces, gravity is the force visible in most day-to-day events, like walking on Earth or the orbiting of planets around the Sun. Newton extrapolated the gravitational force's behavior into universal laws of motion, marking a cornerstone in classical mechanics. His laws have immense implications in the gravitational search algorithm.

The GSA, introduced in this in-depth article, operates on the ...

Read more...
❀2πŸ‘2πŸ‘1
Presenting a straightforward script designed to install a timing mechanism on the main graphics interface. This utility count downs to the commencement of the next data bar, delivering invaluable real-time trend details to the user. Efficiently utilizing time is critical in data visualization tasks. By integrating this tool with existing setups, users will gain the unique advantage of proactively monitoring activity. The primary benefit lies in the anticipation of subsequent trends, granting necessary preparations for the following phase of data movement. Guarantee the effective supervision of data flow with this uncomplicated, yet robust scripting solution.

Read more...
πŸ‘9πŸ‘4❀3
Latest article provides a deep understanding of OpenCL usage through DLL with MQL5. Detailed breakdown guides the audience through successful standalone test and abstraction process for OpenCL into DLL. Topics covered include the proper passing of string from DLL to MQL5 program, building DLL usable by MQL5, and utilizing key APIs offered by OpenCL C++ API.

The work moves into separating the existing codes into a simple DLL that can interact with MQL5, giving a strong idea of the project file structure. Functions like listall and compute are elaborately broken down and their functionalities are thoroughly explained. New concepts such as string conversions, DLOG utility, and handling errors are introduced.

Readers will understand how to manage log buffer, get information about all OpenCL platforms and devices, construct cl::Program::Sources and other OpenCL tasks. Also presented is a...

Read more...
πŸ‘6πŸ”₯2πŸ‘2
In recent technical updates, it has been observed that the execution function for the ONNX model requires explicit definition of input and output dimensions. Such dimensions can be set using the OnnxSetInputShape and OnnxSetOutputShape functions.

It's noteworthy to mention that not all models come with fixed data sizes for input and output. In the event of encountering such models, the script will return -1 as an output.

Further in the user interface experience, the FileSelectDialog function can be employed to choose a model from the MQL5\Files directory. This elucidates how the script handles such actions.

Lastly, a crucial update reveals changes made to the OnnxTypeInfo structure in build 3700 which prompts modifications in the source code of the script. This change facilitates improved performance in handling variable data sizes.

Stay informed about these key changes to stream...

Read more...
❀4πŸ†4πŸ‘3πŸ‘1
Andrews Pitchfork, featured in modern chart analysis software, offers a simplistic yet creative analysis methodology. However, potential users often question the necessity of a variety of pitchforks and how they aid trading. Consultation of Alan Andrew's original course reveals that supply and demand will maintain dynamic equilibrium, causing resources prices to fluctuate around a specific average line. This article attempts to decode the ideas behind the Andrews Pitchfork in an accessible manner.

The methodology begins by attempting to predict market behaviour. Notably in the years prior to computer and neural networks, market predictions were made, leading to the hypothesis that current analytical methods can also achieve forecast accuracy. The baseline belief centres were drawn on physics, more specifically, Newton's third law, which was theorized to be applicable to financial flo...

Read more...
⚑4πŸ‘Œ2πŸ‘1
Staying abreast of the latest technology trends is crucial in this fast-paced world. By mastering new technologies, developers enhance their knowledge, capacity, and competitiveness. Grand technology breakthroughs have dramatically transformed the world, opening new opportunities for businesses and individuals alike. Adopting the emerging technologies grants an edge in today's age.

Artificial Intelligence (AI) demonstrates its capabilities with self-driving cars and personal assistants. This powerful technology is revolutionizing many industries including healthcare, transport, and even space exploration. By its nature, AI has a significant impact on developers, who must keep themselves updated and proficient.

Besides AI, Blockchain technology is another innovation worth noting. Initially developed for the cryptocurrency, Bitcoin, the blockchain has found applications in various oth...

Read more...
πŸ‘4πŸ‘2