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

What are the units that LinRegSlope() returns?

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

    What are the units that LinRegSlope() returns?

    Degrees? Percent?

    My first concern is whether or not a stock with a higher LinRegSlope() for a given period is rising faster (i.e. at a greater percentage rate) than another stock with a lower LinRegSlope? As long as the units are anything like percent or degrees, that works fine, but if they are just $$ ROC then it does not work.

    My second question is how would I convert what LinRegSlope() returns to CAGR?

    Thanks,
    EV

    #2
    EV, this is just a rise over run calculation which is not normalized, though the inverse tangent would give you the slope angle. Turning those values into CAGR would need to some extra coding, I would not be aware of an example shared already unfortunately.
    BertrandNinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_Bertrand View Post
      EV, this is just a rise over run calculation which is not normalized, though the inverse tangent would give you the slope angle. Turning those values into CAGR would need to some extra coding, I would not be aware of an example shared already unfortunately.
      By that do you mean the result is:
      (Linear Regression Value[0] - Linear Regression Value[n]) / n
      I so, that is pretty trivial to convert to CAGR.

      Thanks,
      EV
      Last edited by ETFVoyageur; 02-20-2011, 01:57 PM.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by rhyminkevin, Today, 04:58 PM
      3 responses
      47 views
      0 likes
      Last Post Anfedport  
      Started by iceman2018, Today, 05:07 PM
      0 responses
      5 views
      0 likes
      Last Post iceman2018  
      Started by lightsun47, Today, 03:51 PM
      0 responses
      7 views
      0 likes
      Last Post lightsun47  
      Started by 00nevest, Today, 02:27 PM
      1 response
      14 views
      0 likes
      Last Post 00nevest  
      Started by futtrader, 04-21-2024, 01:50 AM
      4 responses
      50 views
      0 likes
      Last Post futtrader  
      Working...
      X