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

Error on setting indicator plot for indicator

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

    Error on setting indicator plot for indicator

    Just get this error

    Code:
    Error on setting indicator plot for indicator 'SercavaMA'. Value outside of valid range.
    I was trying to apply a personal indicator (some kind of moving average) to another personal indicator whose input data is another personal indicator.

    Applying it to RSI (for example) gives no error and works fine. ¿Perhaps too many personal indicator nested?

    Thanks in advance,

    Sergio

    #2
    Hi Sergio, you would need to look into which nesting produces those unacceptable values as outcomes that NT then in could not display, likely a nested calculation 'blowing up' due to precision issues would be my best guess.

    Here are some example of when this error would be returned to you :
    Plot0.Set(double.MaxValue);

    Plot0.Set(double.NaN);

    Plot0.Set(9999999999999999999999999.0);

    Plot0.Set(double.PositiveInfinity);

    Plot0.Set(double.MinValue);

    Plot0.Set(double.NegativeInfinity);

    Plot0.Set(-9999999999999999999999999.0);
    BertrandNinjaTrader Customer Service

    Comment


      #3
      Is strange, all nested indicators are properly plotted, no one getting extreme values. Will try to check it more deeply.

      Comment


        #4
        You mean when you're plotting them by themselves individually?
        BertrandNinjaTrader Customer Service

        Comment


          #5
          Yes they are correctly plotted individually. Only applying my custom average to the last gives the error. The custom average works well applied to RSI, as said.

          Comment


            #6
            That could still be the case, as the combination could trigger a situation your code would not be prepared to see / handle. You would need to debug the combo then using prints to understand why it blows up.
            BertrandNinjaTrader Customer Service

            Comment


              #7
              Hard work then.Thanks.

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by andrewtrades, Today, 04:57 PM
              1 response
              5 views
              0 likes
              Last Post NinjaTrader_Manfred  
              Started by chbruno, Today, 04:10 PM
              0 responses
              3 views
              0 likes
              Last Post chbruno
              by chbruno
               
              Started by josh18955, 03-25-2023, 11:16 AM
              6 responses
              436 views
              0 likes
              Last Post Delerium  
              Started by FAQtrader, Today, 03:35 PM
              0 responses
              7 views
              0 likes
              Last Post FAQtrader  
              Started by rocketman7, Today, 09:41 AM
              5 responses
              19 views
              0 likes
              Last Post NinjaTrader_Jesse  
              Working...
              X