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 jxs_xrj, 01-12-2020, 09:49 AM
      6 responses
      3,290 views
      1 like
      Last Post jgualdronc  
      Started by Touch-Ups, Today, 10:36 AM
      0 responses
      8 views
      0 likes
      Last Post Touch-Ups  
      Started by geddyisodin, 04-25-2024, 05:20 AM
      8 responses
      61 views
      0 likes
      Last Post NinjaTrader_Gaby  
      Started by Option Whisperer, Today, 09:55 AM
      0 responses
      8 views
      0 likes
      Last Post Option Whisperer  
      Started by halgo_boulder, 04-20-2024, 08:44 AM
      2 responses
      24 views
      0 likes
      Last Post halgo_boulder  
      Working...
      X