Pivot Point Supertrend - MQL5 Code

Поділитися
Вставка
  • Опубліковано 5 жов 2024
  • The is a Metatrader implementation of the Pivot Point Supertrend indicator available on Tradingview.com. I plan to use this indicator in a coming video developing an expert.
    The Pivot Point Supertrend indicator is a variation on the Supertrend indicator that uses a weighted average of high and low pivot points (fractals).
    This video is for MQL5. I have a separate video for MQL4 and there is a link to the MQL4 video below.
    MQL4 Version: • Pivot Point Supertrend...
    If you just want the indicator and not the code this link is to download the compiled version:
    ko-fi.com/s/86...
    To download the Metatrader 4 and 5 platforms and open demo accounts
    MT4: www.orchardfor...
    MT5: www.orchardfor...
    Web: www.orchardfor...
    Twitter: / orchardforex
    Telegram: t.me/orchardforex

КОМЕНТАРІ • 59

  • @OrchardForex
    @OrchardForex  2 роки тому +4

    I found an occasional problem. For me it appears sometimes if I change symbol on a chart that has the indicator already loaded and results in some resistance or support lines disappearing tup or down at the ends. To fix add the following 2 lines before the line "if ( BufferSupport[i + 1] != 0 ) {"
    BufferResistance[i] = 0;
    BufferSupport[i] = 0;

    • @anilvarma9893
      @anilvarma9893 Рік тому +1

      Hi Arthur, Once again thanks a lot for the simplified version of Super Trend. However, I am facing the same problem of disappearing line (In my case Resistance line not show at all). What I have noticed also is that the Resistance value keeps on flipping between support and resistance and that probably causes the line not to draw. However, with Support Line there seems to be no issue. I have added the above two lines, without much success on the Resistance line. Regards.

  • @DittoSwitz
    @DittoSwitz 2 роки тому

    Awesome as always, can't wait for the expert. Thanks you for all you do

    • @OrchardForex
      @OrchardForex  2 роки тому +1

      The expert was due today (Sunday 5th) but we have had some production problems. Coming in a few more days.

    • @DittoSwitz
      @DittoSwitz 2 роки тому

      @@OrchardForex we wait patiently, take your time sir!

  • @MQLwithBrian
    @MQLwithBrian Рік тому

    Again, thank you for this kind of tutorial

  • @EugenePekeur-g7z
    @EugenePekeur-g7z 11 місяців тому

    Thanks so much for the tutorial, my code is working fine..

  • @seyrankasyan9147
    @seyrankasyan9147 11 місяців тому

    the indicator works fine, can I add a multi timeframe in the code? so that I can see, for example, on the M1,M5,...H1 timings, the indicator lines on H4 ?

  • @josias820
    @josias820 9 місяців тому

    Off course !!!

  • @rickyehmer2889
    @rickyehmer2889 2 роки тому

    Great video, I’ve watched most of your tutorials and have broadened my knowledge. Could I please request a video for machine learning or deep learning in MQL5 or even self adapting indicators. Keep up the great work.

    • @OrchardForex
      @OrchardForex  2 роки тому +1

      These videos are not for beginners but machine learning would be several levels further again. Not really my target audience.

    • @rickyehmer2889
      @rickyehmer2889 2 роки тому

      @@OrchardForex Thanks for the reply, would you have any recommendations to acquiring information sought?

    • @OrchardForex
      @OrchardForex  2 роки тому +1

      @@rickyehmer2889 I don't know of anything specific but it is possible to integrate MQL with Python. Perhaps look into Python machine learning.

    • @rickyehmer2889
      @rickyehmer2889 2 роки тому

      @@OrchardForex ok thank you. I’ll look into it

    • @jafxtradinginstitute6395
      @jafxtradinginstitute6395 2 роки тому

      @ricky can we have a conversation? Are you on telegram?

  • @ahmedmihttay6514
    @ahmedmihttay6514 2 роки тому

    This is really Greate Video THANKS

  • @SirLuke33
    @SirLuke33 10 місяців тому

    HI. great video. thanks for this video. Can I ask you without any obligation on your part to create, for mt5, the Kivanc Ozbilgic supertrend found on tradingview ?
    Thank you so much

  • @productvisibilitytvshoppin1107
    @productvisibilitytvshoppin1107 2 роки тому

    Fantastic!

  • @SirLuke33
    @SirLuke33 10 місяців тому

    HI. I get the following error when I change the atr factor value:
    2023.11.19 15:35:44.627 Pivot Point SuperTrend (NZDUSD,H1) array out of range in 'Pivot Point SuperTrend.mq5' (208,30)
    and the line in question would be this:
    double atr = BufferATR[i];
    when I change the value of atrperiod, the same error appears and after a few changes, the lines disappear.
    It also shows up when I change the pivot point value. in this case the lines do not disappear.
    thank you so much

    • @SirLuke33
      @SirLuke33 10 місяців тому

      I added the two lines you recommended with a comment. the problem seems to disappear. the array out of range warning remains when I change the values

    • @SirLuke33
      @SirLuke33 10 місяців тому

      I double-checked the code thoroughly. it does not work well. on currency like jpy it doesn't work because it doesn't have 5 decimals. when I try to change currency, sometimes the graph remains blank and other times it puts lines without meaning. when it remains empty and I change a value, the lines appear.
      the error message remains both when I change currency and when I change a value.
      I have no idea how to fix it. the code is the same as the one in the video.
      My messages are not intended as criticism. I appreciate these videos where you explain what you do.

  • @sagarkadam8267
    @sagarkadam8267 Рік тому

    The provided code in the video is insufficient to draw indicators on the chart. If you can't share the MQL file in that case make sure you show the working code in the video. It takes time to write a code with video and in the end, it's not working as expected.

  • @MyRealityIsProof
    @MyRealityIsProof 2 роки тому

    Thank you for the lesson. Does OF have an MQL5 course?

    • @OrchardForex
      @OrchardForex  2 роки тому +1

      Sorry, no. I have trouble getting my head around structuring a course.

    • @jafxtradinginstitute6395
      @jafxtradinginstitute6395 2 роки тому

      @@OrchardForex how the pivot points are calculated can there be an option to adjust settings which would include the average price of daily and weekly candle. ?

  • @solaris4015
    @solaris4015 Рік тому

    whenever i change the parameters the lines disappears. any clues on what it might be?

  • @productvisibilitytvshoppin1107
    @productvisibilitytvshoppin1107 2 роки тому

    This question is off the topic of the video. The video is very informative but I have this nagging question that in my opinion only you can answer. How could you write code (maybe in a script or in the OnInit ) to automatically add an EA to a chart?

    • @OrchardForex
      @OrchardForex  2 роки тому

      You can't do it without calling external DLLs like the windows API

  • @farhanghonarmand
    @farhanghonarmand Рік тому

    Could you add an alert to the indicator ?

  • @LORDSC11
    @LORDSC11 Рік тому

    Nice videos man but there is a problem in 26:07, you skipped the video and added more line of code.

    • @OrchardForex
      @OrchardForex  Рік тому

      No problem, ignore the line numbers

    • @LORDSC11
      @LORDSC11 Рік тому

      @@OrchardForex Yeah that's the issue, mine never work

  • @sasisas786
    @sasisas786 2 роки тому

    can you build delta candle or delta box indicator on window 1, like platform Quantower

    • @OrchardForex
      @OrchardForex  2 роки тому

      I'm not familiar with this indicator.

  • @gilbertofulcheri9143
    @gilbertofulcheri9143 Рік тому

    hi, i just finished copyng your code but i in my chart the resistence line is not plotted and i dont know why, can u share the entire code so i can understand where is my mistake? thank u in advance

    • @OrchardForex
      @OrchardForex  Рік тому

      I don't have a code download for this, only the compiled version. If one line is not plotted then you might try running in debug mode and look for 1) is it ever assigned a value 2) have you set the correct number of buffers and plots in the property statements

  • @just1347
    @just1347 2 роки тому

    Where do we download the code for this? Thanks

    • @OrchardForex
      @OrchardForex  2 роки тому

      You can only get the code by copying the video.

    • @just1347
      @just1347 2 роки тому

      @@OrchardForex thank you so much, could you please do a code of adding the buy and sell pop up when the buffer upper or lower switches thanks

    • @OrchardForex
      @OrchardForex  2 роки тому

      @@just1347 I don't think that would be a popular topic.

  • @kxng_kav5534
    @kxng_kav5534 2 роки тому

    This doesn't work you said it but in code "Not a real pivot point"

    • @OrchardForex
      @OrchardForex  2 роки тому

      This uses points more like fractals. The formula for a pivot is (h+l+c)/3

    • @kxng_kav5534
      @kxng_kav5534 2 роки тому

      @@OrchardForex Thank you Mr Orchard

    • @kxng_kav5534
      @kxng_kav5534 2 роки тому

      On days as these whenever I'm not successful in my coding I dream of a parallel universe where I'm your grandson or mentee

  • @razeen_Kasandas786
    @razeen_Kasandas786 2 роки тому

    i have copied it but more lines have been added at 26 : 07

    • @OrchardForex
      @OrchardForex  2 роки тому

      The "One more thing I forgot" was edited in after I added the code shown later in the video.

    • @razeen_Kasandas786
      @razeen_Kasandas786 2 роки тому

      I meant to say in the video at 25:55 there is 185 lines of coding and at 26:07 there is 196,where can I find the other 11 lines of coding?

    • @OrchardForex
      @OrchardForex  2 роки тому

      @@razeen_Kasandas786 Same answer

    • @razeen_Kasandas786
      @razeen_Kasandas786 2 роки тому

      Correction 187 lines of coding, I need 8 more lines of coding to get to 195

    • @OrchardForex
      @OrchardForex  2 роки тому

      @@razeen_Kasandas786 You shouldn't be missing any code. With the update later and the editing where I missed code the first time through the auto formatter added some comments and line breaks above. But see the pinned comment about the additional 2 lines for a bug I found.

  • @HamzahAli189
    @HamzahAli189 Рік тому

    hi how can add buy and sell label just like in tradingview

    • @OrchardForex
      @OrchardForex  Рік тому

      T look like tv buy/sell labels you would have to draw label onjects on screen for MT

  • @seyrankasyan9147
    @seyrankasyan9147 11 місяців тому

    the indicator works fine, can I add a multi timeframe in the code? so that I can see, for example, on the M1,M5,...H1 timings, the indicator lines on H4 ?