Building Linear Regression in Python
Yes, I know — there is a built in function in the python numpy module that does linear (and other powers) fitting. It looks like this.
m,b = polyfit(x, y, 1)
But what if you are using VPython (Glowscript)? This is the online version of python with the built in visual module. It has awesome stuff for making graphs, vector calculations, and even 3D visualizations. But what if you want to use Glowscript AND find a linear function that best fits some points or data? What then?