Hello dear friends and traders. I recently started learning the MQL programming language and therefore wanted to ask how to draw a horizontal line on each candle in certain time frames (for example, annual, semi-annual, monthly and weekly) in open, close and min.max prices. This needs to be done better by downloading the entire history of a particular trading pair. And what is better to do this on an advisor, on an indicator or on a script? Maybe someone already has experience, tell me the right way to implement such an idea, please. Thank you for your attention.
- [ARCHIVE] Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Nowhere without you - 3.
- Indicator for High-Low Weekly and Monthly candle
- How I assemble my advisor by trial and error
o.mansurov:
Hello dear friends and traders. I recently started learning the MQL programming language and therefore wanted to ask how to draw a horizontal line on each candle in certain time frames (for example, annual, semi-annual, monthly and weekly) in open, close and min.max prices. This needs to be done better by downloading the entire history of a particular trading pair. And what is better to do this on an advisor, on an indicator or on a script? Maybe someone already has experience, tell me the right way to implement such an idea, please. Thank you for your attention.
Most programmers use line objects. Hello dear friends and traders. I recently started learning the MQL programming language and therefore wanted to ask how to draw a horizontal line on each candle in certain time frames (for example, annual, semi-annual, monthly and weekly) in open, close and min.max prices. This needs to be done better by downloading the entire history of a particular trading pair. And what is better to do this on an advisor, on an indicator or on a script? Maybe someone already has experience, tell me the right way to implement such an idea, please. Thank you for your attention.
Personally, I prefer canvas. Less code, more features, better performance.
https://www.mql5.com/en/forum/459746/page2#comment_51489780
o.mansurov:
Hello dear friends and traders. I recently started learning the MQL programming language and therefore wanted to ask how to draw a horizontal line on each candle in certain time frames (for example, annual, semi-annual, monthly and weekly) in open, close and min.max prices. This needs to be done better by downloading the entire history of a particular trading pair. And what is better to do this on an advisor, on an indicator or on a script? Maybe someone already has experience, tell me the right way to implement such an idea, please. Thank you for your attention.
Hello dear friends and traders. I recently started learning the MQL programming language and therefore wanted to ask how to draw a horizontal line on each candle in certain time frames (for example, annual, semi-annual, monthly and weekly) in open, close and min.max prices. This needs to be done better by downloading the entire history of a particular trading pair. And what is better to do this on an advisor, on an indicator or on a script? Maybe someone already has experience, tell me the right way to implement such an idea, please. Thank you for your attention.
You can use Objects but keep in mind drawing too much objects may slow down performance of your indicator. You should consider drawing with buffers if you want to draw resource friendly lines. I have no idea about performance of canvas with 1000+ objects
Of course, canvas is traditionally (including in Web development (JS)) a technology with maximum performance, since canvas is one object(It's just an array of pixels ). Canvas works fine with more than 10,000 objects. And if you use OpenCl for the canvas, it works without lags and with more than 100,000 objects.
Try doing something like this on objects:

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register