Navigating through the labyrinth of programming concepts might seem difficult for newbies, but comprehending the essence of 'Function' can pave a pathway towards creating highly functional and top-quality software.
Understanding what functions are, the rationale behind using them, and how to effectively utilize them can undeniably be beneficial for any software developer. For instance, taking a small step like learning to write functions with arguments, and then gradually proceeding to function overloading can greatly enhance one's programming skills.
Implementing functions enables methods such as abstracting code, thereby reducing redundancy and promoting reusability. Apart from making the code more readable, functions boost debugging process efficiency, making error detection and resolution considerably easier.
Delving into further contexts like 'call-by-value' and 'call-by-refe...
Read more...
Understanding what functions are, the rationale behind using them, and how to effectively utilize them can undeniably be beneficial for any software developer. For instance, taking a small step like learning to write functions with arguments, and then gradually proceeding to function overloading can greatly enhance one's programming skills.
Implementing functions enables methods such as abstracting code, thereby reducing redundancy and promoting reusability. Apart from making the code more readable, functions boost debugging process efficiency, making error detection and resolution considerably easier.
Delving into further contexts like 'call-by-value' and 'call-by-refe...
Read more...
👍4👏1
Introducing a performance-boosting tool for traders: an advanced indicator that quantifies market noise with precision. Traders can now have a clearer distinction between periods of high and low volatility, thanks to its straightforward graphical representation.
A visual representation minimizes room for subjective interpretation and aids swift decision-making. Not only does this result in a smoother trading process, but also paves the way for the implementation of diverse trading strategies.
Standout features don't end there. This tool promises a new degree of accuracy and objectivity. Volatility, a key parameter in trading, can now be understood and integrated into the trading process more effectively. Take advantage of this tool, apprehend market noise like never before and enhance the quality of trading decisions.
A step towards technical sophistication, this innovative indica...
Read more...
A visual representation minimizes room for subjective interpretation and aids swift decision-making. Not only does this result in a smoother trading process, but also paves the way for the implementation of diverse trading strategies.
Standout features don't end there. This tool promises a new degree of accuracy and objectivity. Volatility, a key parameter in trading, can now be understood and integrated into the trading process more effectively. Take advantage of this tool, apprehend market noise like never before and enhance the quality of trading decisions.
A step towards technical sophistication, this innovative indica...
Read more...
👍6❤2🤝2
The crux of effective trading ventures lies in the potential astuteness within the binary of category theory and order theory. Offering insights, the previous article discussed the implementation of this theoretical union in MQL5 and elaborated on how these concepts fuel a trading system. The focus rested primarily on partial and linear orders, both concepts lending interesting perspectives to set ranking methods.
A powerful stride in syncing category theory with database schemas is the classification of calendar events. These preordained events, marked months in advance, spotlight indicators for an array of economies, including China, the US, Japan, Germany, EU, UK, South Korea, Singapore, Switzerland, Canada, New Zealand, Australia, and Brazil. Varied in their format, these indicators usually present numeric values such as forecast, actual, and previous values, but often feature co...
Read more...
A powerful stride in syncing category theory with database schemas is the classification of calendar events. These preordained events, marked months in advance, spotlight indicators for an array of economies, including China, the US, Japan, Germany, EU, UK, South Korea, Singapore, Switzerland, Canada, New Zealand, Australia, and Brazil. Varied in their format, these indicators usually present numeric values such as forecast, actual, and previous values, but often feature co...
Read more...
👍2👌1
A new ONNX script is available to aid machine learning model creation. This script offers the user an ability to select the ONNX model file seamlessly, followed by a prompt indicating model processing. Information from the input and output tensors in the model is carefully harnessed and displayed for user convenience, making the debugging process hassle-free.
If an error occurs during ONNX session creation, a prompt is displayed to facilitate immediate rectification. Additionally, the script enables the inspection of ONNX models' structure, transforming the understanding of input and output tensors, their names, and properties.
Such insight is critical in facilitating a deeper understanding of machine learning model structures, especially in ONNX models, which has significant ramifications in machine learning applications. Therefore, it simplifies the muddling task of debugging an...
Read more...
If an error occurs during ONNX session creation, a prompt is displayed to facilitate immediate rectification. Additionally, the script enables the inspection of ONNX models' structure, transforming the understanding of input and output tensors, their names, and properties.
Such insight is critical in facilitating a deeper understanding of machine learning model structures, especially in ONNX models, which has significant ramifications in machine learning applications. Therefore, it simplifies the muddling task of debugging an...
Read more...
🔥5❤3💯2
Reflecting upon the previous discourse "Developing a Replay System — Market simulation (Part 01): First experiments (I)", the concept of creating an event system for generating an adequate market simulation presented certain limitations. Notably, the 10-millisecond mark seemed unreachable, significantly impacting the system's effectiveness. Studying the related attachments elucidates this point, revealing that even the 10-millisecond range might not be sufficient.
Efforts to attain a 1- or 2-millisecond execution timeframe confronted inherent operational barriers. The operating system's timer is incapable of reaching these values, thereby creating a significant impediment. Despite this, the existing system still affords a number of computational possibilities that can be exploited.
Attempting to attribute the failure to reach the 1-minute mark to modern processor limitations reveal...
Read more...
Efforts to attain a 1- or 2-millisecond execution timeframe confronted inherent operational barriers. The operating system's timer is incapable of reaching these values, thereby creating a significant impediment. Despite this, the existing system still affords a number of computational possibilities that can be exploited.
Attempting to attribute the failure to reach the 1-minute mark to modern processor limitations reveal...
Read more...
❤4👍2👌1
Software developers targeting the application of the revered Martin Gale strategy in trading systems can cash in on this advanced library without any hitches. The 'include file' extends two essential classes - GridStrategy and MartinGaleStrategy - from the base Strategy class.
Key attributes to note include 'Startprice', 'Lots' (the volume on offer for the tactics), 'TakeProfit', and 'Stoploss' (given in financial terms). The Grid and Martin Gale strategies are inherently distinguished, but retain the fundamental characteristics tied to the Strategy class.
Attention must be drawn to a consequential function - the 'onTick' routine, a property of the Strategy class. It is to be activated within the realm of the OnTick() function in an Expert Advisor. This function plays a pivotal role, dealing with every facet of the strategy. This stretches from churning out buy and sell indicators,...
Read more...
Key attributes to note include 'Startprice', 'Lots' (the volume on offer for the tactics), 'TakeProfit', and 'Stoploss' (given in financial terms). The Grid and Martin Gale strategies are inherently distinguished, but retain the fundamental characteristics tied to the Strategy class.
Attention must be drawn to a consequential function - the 'onTick' routine, a property of the Strategy class. It is to be activated within the realm of the OnTick() function in an Expert Advisor. This function plays a pivotal role, dealing with every facet of the strategy. This stretches from churning out buy and sell indicators,...
Read more...
👍8✍1
Developers, traders, your attention, please. Let's take a meticulous look into the possibilities that lurk within MQL5 programming. How about expanding the functionality of the MetaTrader 5 platform to complement your trading process? Sounds like an intriguing experiment, doesn't it?
We'll focus on the major issue raised by several traders - the lack of a market simulation or replay system within MetaTrader 5 platform. Keeping this in mind, the aim is to develop a replay and simulation system, allowing market participants to try out, examine or study assets more effectively.
As intriguing as it sounds, don't expect an overnight win, you must have some programming knowledge to make the most of it. Replica of real-time movements, implementation of a trading system that checks each trade closely, and thorough tick data analysis for each asset are to be expected in our quest.
Yet, the...
Read more...
We'll focus on the major issue raised by several traders - the lack of a market simulation or replay system within MetaTrader 5 platform. Keeping this in mind, the aim is to develop a replay and simulation system, allowing market participants to try out, examine or study assets more effectively.
As intriguing as it sounds, don't expect an overnight win, you must have some programming knowledge to make the most of it. Replica of real-time movements, implementation of a trading system that checks each trade closely, and thorough tick data analysis for each asset are to be expected in our quest.
Yet, the...
Read more...
👍3❤1
The contemporary library presented allows an effortless interface with PNG graphic files and provides options for scaling them. PNG images can be uploaded in two ways: either via direct file upload or sourced from within an ex5 file.
When working with PNG images via resources, an immediate canvas can be formed and the images can be directly screened. Alternatively, the creation of a bmp[] bitmap array, discarding the step to create a canvas object for the image, can also be pursued. The bmp[] array can find pulse in more advanced implementations with proprietary canvases.
An imperative feature of the CPng class is the Resize(double NewWidth) method. It fosters the generation of new image sizes within the _bmp[] array, which can be screened by forming the canvas of corresponding size. The class instance will thus carry two bmp[] arrays (original size) with width "width" and height "h...
Read more...
When working with PNG images via resources, an immediate canvas can be formed and the images can be directly screened. Alternatively, the creation of a bmp[] bitmap array, discarding the step to create a canvas object for the image, can also be pursued. The bmp[] array can find pulse in more advanced implementations with proprietary canvases.
An imperative feature of the CPng class is the Resize(double NewWidth) method. It fosters the generation of new image sizes within the _bmp[] array, which can be screened by forming the canvas of corresponding size. The class instance will thus carry two bmp[] arrays (original size) with width "width" and height "h...
Read more...
👍10😁1🎉1
Unveiling a technical strategy that employs a combination of indicators and tools to generate trading signals and targets. Noteworthy components include a 14-period stochastic oscillator, a 5-period stochastic oscillator, a 200-period moving average, and a Fibonacci projection tool. The stochastic oscillator, developed by George C. Lane, calculates a financial instrument's price momentum and strength. Amid trading, if the stochastic oscillator verges on the lower boundary, it indicates oversold levels and a bullish bias. Conversely, nearing the upper boundary flags overbought levels and a bearish bias.
Meanwhile, with the moving average technique, data is smoothed over a particular period to identify trends and formulate trading signals. This method calculates by averaging a given set of prices over a specific time, then updates as new data becomes available. Older data points are s...
Read more...
Meanwhile, with the moving average technique, data is smoothed over a particular period to identify trends and formulate trading signals. This method calculates by averaging a given set of prices over a specific time, then updates as new data becomes available. Older data points are s...
Read more...
👍7❤3👏1
In the ever-evolving world of web development and programming, staying updated about the latest trends, technologies, and best practices is paramount. Recent advancements in Cloud Computing, Continuous Integration/Continuous Deployment (CI/CD), and the rise of containerization have significantly influenced our workflows and approach to software development.
Artificial Intelligence and Machine Learning applications are now more accessible and prevalent, with libraries and frameworks like TensorFlow, PyTorch, and Keras leading the charge. Coding languages like Python, JavaScript, and TypeScript remain popular, while Rust and Go are also gaining traction.
Web development sees a broad adoption of JavaScript and its frameworks such as React.js and Vue.js. Full-stack JavaScript development with Node.js on the backend continues to be a preferred approach for many developers. HTML5 and CSS3...
Read more...
Artificial Intelligence and Machine Learning applications are now more accessible and prevalent, with libraries and frameworks like TensorFlow, PyTorch, and Keras leading the charge. Coding languages like Python, JavaScript, and TypeScript remain popular, while Rust and Go are also gaining traction.
Web development sees a broad adoption of JavaScript and its frameworks such as React.js and Vue.js. Full-stack JavaScript development with Node.js on the backend continues to be a preferred approach for many developers. HTML5 and CSS3...
Read more...
👍12
Invest in technical knowledge, nurture coding skills, and simplify complex tasks with the use of MQL5 classes while developing MetaTrader5 applications. The comparison of building a graphical panel application using standard code and class libraries demonstrates the efficiency gained through the latter. Without the use of classes, code lines increase considerably. In contrast, the use of pre-defined classes such as Panels, Dialogs, Button, Edit, and Trade effectively reduces this complexity and enhances functionality. Save time, avoid repetitive coding tasks, boost productivity, and focus more on logic and quality development rather than basic code creation. Developers are urged to gain mastery of ready-made classes and built-in functions for improved coding skills. It helps in better understanding and designing customized requirements for trading panels; a vital component that aids t...
Read more...
Read more...
👍4❤3👏1
Understanding the dynamic nuances of trading strategies is elemental. Highlighted here is a contrast between the wide-known Trailing Stop and the recently presented Trailing Take Profit. The former tracks price fluctuations until the stop loss hits, rendering the position closed profitably. The latter, instead, trails the price when a position is incurring loss, leading ultimately to the position's closure at a loss.
Consider a scenario: A position is sinking into losses when the current price reaches the TrailingTPStart. For example, if the TrailingTPStart is 500 points, the price reaches 500 points from the opening price, and the position is at a downward spiral of -500 points, this is where Take profit begins its trail. The TrailingTPDistance canvasses for the largest distance between the trailing take profit and the current price.
While this concept's utility may vary, it coul...
Read more...
Consider a scenario: A position is sinking into losses when the current price reaches the TrailingTPStart. For example, if the TrailingTPStart is 500 points, the price reaches 500 points from the opening price, and the position is at a downward spiral of -500 points, this is where Take profit begins its trail. The TrailingTPDistance canvasses for the largest distance between the trailing take profit and the current price.
While this concept's utility may vary, it coul...
Read more...
👍7👏2❤1
To those looking to enter the realm of MQL5 programming, this article aims to provide a basic guide. It's important to stress, that novice programmers should not be deterred by their lack of experience. The road to MQL5 mastery is filled with trials and errors, but that's the essence of learning.
It's a misconception that to become a proficient coder, one must enrol in courses. It's through consistent practice and experimentation that one learns to mold a code to their preferences. One should always be observant of more experienced programmers, and adapt working source codes to their needs.
For beginners without prior knowledge in programming, learning C language provides the fundamentals for syntax and logic. Once C language is clearly understood, transitioning into C++ and reapplying the skills into MQL5 should be seamless.
Finding a mentor willing to guide through the process...
Read more...
It's a misconception that to become a proficient coder, one must enrol in courses. It's through consistent practice and experimentation that one learns to mold a code to their preferences. One should always be observant of more experienced programmers, and adapt working source codes to their needs.
For beginners without prior knowledge in programming, learning C language provides the fundamentals for syntax and logic. Once C language is clearly understood, transitioning into C++ and reapplying the skills into MQL5 should be seamless.
Finding a mentor willing to guide through the process...
Read more...
❤3👍3🔥2✍1⚡1
In the realm of technical trading, the importance of effective chart analysis cannot be overstated. The Candle ZigZag indicator has emerged as a reliable tool in this aspect. Unlike the traditional line chart, which represents price movements in curves, Candle ZigZag helps traders analyze charts in a more distinct and clean-cut 'flat' mode.
A key attribute of the Candle ZigZag is its responsiveness to candlestick color changes, which prompts alterations in its leg. Another critical feature is its support for a period of 1. Notably, the standard ZigZag in the example folder lacks this function.
Users also have the convenience of enabling and disabling the 'close mode' as per their analysis preference. The difference in perspective becomes apparent when comparing Candle ZigZag (with close mode= true) to a standard line chart. The analysis becomes easier and more precise, charting new...
Read more...
A key attribute of the Candle ZigZag is its responsiveness to candlestick color changes, which prompts alterations in its leg. Another critical feature is its support for a period of 1. Notably, the standard ZigZag in the example folder lacks this function.
Users also have the convenience of enabling and disabling the 'close mode' as per their analysis preference. The difference in perspective becomes apparent when comparing Candle ZigZag (with close mode= true) to a standard line chart. The analysis becomes easier and more precise, charting new...
Read more...
❤7👍4
Discover the merge of Heiken-Ashi charting and moving averages as a trend confirmation technique in this enlightening piece. Safely understand bullish, bearish, and Doji situations in market fluctuations using Heiken-Ashi (meaning "average pace"), a Japanese trading indicator that clarifies market trends by smoothing out OHLC data.
An introduction to Moving Averages is also covered, shedding light on the power of this versatile tool. Utilized to detect dynamic support and resistance levels, stops and targets, and the underlying trend, understanding moving averages is an essential part of any developer's toolkit.
Coding enthusiasts will find a comprehensive walk-through on generating trading signals using Heiken-Ashi charting and moving averages in the MetaQuotes Language 5 (MQL5). Lean about the functioning of a piece of code that opens and closes positions based on Heiken-Ashi and ...
Read more...
An introduction to Moving Averages is also covered, shedding light on the power of this versatile tool. Utilized to detect dynamic support and resistance levels, stops and targets, and the underlying trend, understanding moving averages is an essential part of any developer's toolkit.
Coding enthusiasts will find a comprehensive walk-through on generating trading signals using Heiken-Ashi charting and moving averages in the MetaQuotes Language 5 (MQL5). Lean about the functioning of a piece of code that opens and closes positions based on Heiken-Ashi and ...
Read more...
👍4🔥2
Unveiling a practical function for applying linear regression in pine script: the linreg(source, length, offset) function. As the cornerstone of financial analysis, linear regression delineates the best approach to align with price trends over specified periods. It magnifies precision through the least squares method.
The function's mechanics are encapsulated in this formula: linreg = intercept + slope * (length - 1 - offset). Parameters comprise the length as the y argument, offset as the z argument, while both intercept and slope derive from least squares computation on the source series (x argument).
The linreg function shines as an expeditious copy-paste instrument in projects transitioning from the tradingview platform. Bolster your coding arsenal with this function, enhancing accuracy, and efficiency.
Read more...
The function's mechanics are encapsulated in this formula: linreg = intercept + slope * (length - 1 - offset). Parameters comprise the length as the y argument, offset as the z argument, while both intercept and slope derive from least squares computation on the source series (x argument).
The linreg function shines as an expeditious copy-paste instrument in projects transitioning from the tradingview platform. Bolster your coding arsenal with this function, enhancing accuracy, and efficiency.
Read more...
❤5👍4👏2😁1🏆1
Continuing the exploration of the creation of a movable dashboard, the second part of the series brings further clarity through a refined method, suitable for EA/Indicator applications. The task of producing multiple movable dashboards calls for a streamlined process - thanks to .mqh files, this can be made simpler. This discussion will shed light on understanding the concept of classes, spotlighting their utility in developing functions and variables and exploring their fundamentals. Classes equip coders with improved management capabilities, making it easier to maneuver increasing complexity. This piece will also guide on creating and declaring classes, writing them, and effectively using them. Classes in .mq5 and .mqh are explored in depth, illuminating the addition of variables and values, and explaining constructors and destructors. Readers will also learn about access modifiers ...
Read more...
Read more...
👍5👏1
Presenting the all-encompassing 'Collect All Indicators Script' designed with an aim to amass all MQL5 in-built indicators buffers and save them in an easily accessible CSV file for meticulous analysis.
Bollinger Bands are represented through BASE_LINE, UPPER_BAND, and LOWER_BAND. The Average Directional Movement Index (ADX) portrays itself through MAIN_LINE, PLUSDI_LINE, and MINUSDI_LINE.
Diverse general indicators have been incorporated such as, Double Exponential Moving Average (DEMA), Fractal Adaptive Moving Average (FRAMA), Moving Average (MA), Parabolic SAR, Standard Deviation (StdDev), Triple Exponential Moving Average (TEMA), and Variable Index Dynamic Average (ViDyA).
Oscillators include Average True Range (ATR), Bears Power, Bulls Power, Chainkin Oscillator, Commodity Channel Index (CCI), DeMarker, Force Index, and multiple more. Indicators like Accumulator Distributor (...
Read more...
Bollinger Bands are represented through BASE_LINE, UPPER_BAND, and LOWER_BAND. The Average Directional Movement Index (ADX) portrays itself through MAIN_LINE, PLUSDI_LINE, and MINUSDI_LINE.
Diverse general indicators have been incorporated such as, Double Exponential Moving Average (DEMA), Fractal Adaptive Moving Average (FRAMA), Moving Average (MA), Parabolic SAR, Standard Deviation (StdDev), Triple Exponential Moving Average (TEMA), and Variable Index Dynamic Average (ViDyA).
Oscillators include Average True Range (ATR), Bears Power, Bulls Power, Chainkin Oscillator, Commodity Channel Index (CCI), DeMarker, Force Index, and multiple more. Indicators like Accumulator Distributor (...
Read more...
👍3❤1🎉1
MetaTrader users often require real-time data sharing, such as trade transactions and account info, using technology like network sockets or web services. A solution could be the MQTT protocol since it offers high performance, low bandwidth consumption, minimal resource requirements, and affordability. While trade copiers are a frequently observed usage case, uses could extend beyond this, providing real-time data for machine learning pipelines, modifying EA performance due to real-time data, or operating MetaTrader from anywhere. Free and open-source MQTT libraries are available for various languages. While DLL-dependency presents some challenges, a native MQTT library for MetaTrader is an alternative.
In MQTT, the packet type determines the operational behavior. MQTT used in pub/sub and follows a standard for data transmission, called "packets", and each packet could contain up to...
Read more...
In MQTT, the packet type determines the operational behavior. MQTT used in pub/sub and follows a standard for data transmission, called "packets", and each packet could contain up to...
Read more...
👍4
For those involved in Forex trading, there are techniques designed to manage open trades and mitigate risk. One such method consists of trading with uniform symbol and type selections, for instance, exclusively using GBPUSD and employing the 'BUY' option. There's a script designed specifically for this approach, the purpose of which is to secure a trader's position by implementing one significant trade as a hedge. The script then proceeds using the CloseBy() function to progressively counterbalance all open trades against this larger trade, continuing the process until all are resolved. It should be noted, for operational clarity, that this process can handle a maximum of 500 concurrent open trades. This volume should cater for most traders' needs and promote a more streamlined trading process. It's a practical approach to trade management illustrating how scripts can be harnessed as ...
Read more...
Read more...
❤5👍4