taylor_o

regress

Library "regress"
produces the slope (beta), y-intercept (alpha) and coefficient of determination for a linear regression

regress(x, y, len) regress: computes alpha, beta, and r^2 for a linear regression of y on x
  Parameters:
    x: the explaining (independent) variable
    y: the dependent variable
    len: use the most recent "len" values of x and y
  Returns: : alpha is the x-intercept, beta is the slope, an r2 is the coefficient of determination

Note: the chart does not show anything, use the return values to compute model values in your own application, if you wish.
Biblioteca Pine

Siguiendo el verdadero espíritu de TradingView, el autor de este código de Pine lo ha publicado como biblioteca de código abierto, para que el resto de programadores de Pine de esta comunidad puedan volver a utilizarlo. ¡Un hurra por el autor! Puede utilizar esta biblioteca de forma privada o en otras publicaciones de código abierto, pero debe ceñirse a lo establecido en las Normas internas.

Exención de responsabilidad

La información y las publicaciones que ofrecemos, no implican ni constituyen un asesoramiento financiero, ni de inversión, trading o cualquier otro tipo de consejo o recomendación emitida o respaldada por TradingView. Puede obtener información adicional en las Condiciones de uso.

¿Quiere utilizar esta biblioteca?

Copie la siguiente línea y péguela en su script.