• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

LinRegSlopePlus indicator exponential calculation

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

    LinRegSlopePlus indicator exponential calculation

    Hello, please would like to understand how is the LinRegSlopePlus calculation done when the exponential option is set to true.
    Looking for some reference on the internet, I found something on Exponential Regresion:
    http://www.zweigmedia.com/RealWorld/...egression.html

    I am not sure if this is the approach that is used on this indicator, and I couldn`t find any reference on the indicator and the techniques that are used.

    I guess the confusion is because an exponential regression would be a non-linear function, so an exponential linear regression would be nonsense.

    Thank you very much.
    Last edited by algotrade; 01-06-2015, 05:58 PM.

    #2
    algotrade, you might want to PM the original author to explain potentially in more detail - what I can see as explanation resides as comment in the source file -

    'This function calculates a linear regression slope using exponential
    moving averages as the summation terms in the slope formula. A
    simple average multiplied by the number of elements equals the sum,
    so we can calcuate the regression slope using simple averages.
    However, if we replace the simple averages in the computation by
    exponential averages, the resulting slope magnitude turns out larger
    by a factor of 3N/(N+1), where N is the number of elements, therefore
    we must divide the result by this correction factor (this simple
    correction was actually a lot of work to figure out).

    The correction factor will give perfect results for regions of
    perfectly constant slopes, but for noisy data like markets, the
    response time of the exponential average will make the SWINGS in
    slope magnitude appear smaller than the actual regression slope,
    although the slope will be smoother in areas of fairly constant slope.'
    BertrandNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Boonfly8, Today, 02:04 PM
    0 responses
    2 views
    0 likes
    Last Post Boonfly8  
    Started by Branpo, Today, 01:25 PM
    3 responses
    7 views
    0 likes
    Last Post NinjaTrader_ChrisL  
    Started by aslane, Today, 12:47 PM
    1 response
    5 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by HavasuTrader, Today, 12:30 PM
    1 response
    10 views
    0 likes
    Last Post NinjaTrader_PatrickG  
    Started by Boonfly8, Today, 12:20 PM
    1 response
    3 views
    0 likes
    Last Post NinjaTrader_PaulH  
    Working...
    X