I have to use Excel's LINEST function to compute error in my linear regression. I was hoping to reproduce the results using Numpy's polyfit function. I was hoping to reproduce the following LINEST usage:
LINEST(y's, x's,,TRUE)
with polyfit. I'm not sure how I can get the two functions to produce the same values because nothing I've tried gives similar results.
I tried the following:
numpy.polyfit(x,y,3)
and various other values in the third position.