Polynomial regression: Difference between revisions

m
(→‎{{header|PARI/GP}}: alternate code due to Bill Allombert)
Line 523:
 
=={{header|PARI/GP}}==
[http://mathworld.wolfram.com/LagrangeInterpolatingPolynomial.html Lagrange interpolating polynomial]:
<lang parigp>polinterpolate([0,1,2,3,4,5,6,7,8,9,10],[1,6,17,34,57,86,121,162,209,262,321])</lang>
Output:
Line 533:
Output:
<pre>3*x^2 + 2*x + 1</pre>
 
<small>Code thanks to [http://pari.math.u-bordeaux.fr/archives/pari-users-1105/msg00006.html Bill Allombert]</small>
 
=={{header|Python}}==