slope and intercept inverted in OLS_Slope_InterceptN
André Tavares last edited by
The class OLS_Slope_InterceptN calculates slope and intercept. However I think it is on the wrong order. It is as follows:
slope, intercept = sm.OLS(p0, p1).fit().params
I think the correct is:
intercept, slope = sm.OLS(p0, p1).fit().params
I am right?
Tom Feron last edited by
Yes. I came here to report the same issue.
run-out last edited by
Added as an issue in Backtrader2... https://github.com/backtrader2/backtrader/issues/28