Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Changing an indicators value scale...?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Changing an indicators value scale...?

    Hi.

    I have the default MACD indie, and I have the Elliott Oscillator from the Indicators library here on the forum. They basically do the same thing, but I want the slow plot from the MACD to be overlaid on the fast plot from the oscillator. Not a problem, other than the fact that the MACD has a value scale that runs 0, 1, 2, 3, etc whereas the oscillator plots to 0, 0.1, 0.2, 0.3 etc. So, 1/10th the scale.

    How might I adjust the code in one or the other so they match (don't care which has to change)

    Please.

    Thank you.

    #2
    You could multiply the EW oscillator plot value then by 10 in the code.
    BertrandNinjaTrader Customer Service

    Comment


      #3
      Thanks Bertrand. You make it sound so simple — and I'm sure it is — but I'm staring at this code with the eyes of a non-coder and... haven't a clue how to do that.

      Could ya point me in the right direction perhaps?

      Many thanks

      Comment


        #4
        You have to pull up the Oscillator code and multiply its calculated value by 10. Unfortunately I cannot direct you as to where you would need to make these changes since that is 3rd party code. Generally just the final location that calculates out the plot value, multiply that by 10 before setting.

        Value.Set(someValue * 10);
        Josh P.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by habeebft, Today, 07:27 AM
        1 response
        11 views
        0 likes
        Last Post NinjaTrader_ChristopherS  
        Started by AveryFlynn, Today, 04:57 AM
        1 response
        12 views
        0 likes
        Last Post NinjaTrader_Erick  
        Started by Max238, Today, 01:28 AM
        4 responses
        37 views
        0 likes
        Last Post Max238
        by Max238
         
        Started by r68cervera, Today, 05:29 AM
        1 response
        10 views
        0 likes
        Last Post NinjaTrader_ChelseaB  
        Started by geddyisodin, Today, 05:20 AM
        1 response
        14 views
        0 likes
        Last Post NinjaTrader_Gaby  
        Working...
        X