Displaying 3 results from an estimated 3 matches for "polyvers".
Did you mean:
polymers
2004 Aug 09
1
returns the value of a polynomial of degree n evaluated at x.
> Background:
> OS: Linux Mandrake 9.1
> release: R 1.9.0
> editor: Xemacs 21.4
> frontend: ESS 5.1.23
> ---------------------------------
>
> Colleagues
>
Is there a function in R that is similar to polyval in matlab? (y =
polyval(p,x) returns the value of a polynomial of degree n evaluated at x.
The input argument p is a vector of length n+1 whose elements are the
2007 Aug 15
1
Polynomial fitting
Hi everybody!
I'm looking some way to do in R a polynomial fit, say like polyfit
function of Octave/MATLAB.
For who don't know, c = polyfit(x,y,m) finds the coefficients of a
polynomial p(x) of degree m that fits the data, p(x[i]) to y[i], in a
least squares sense. The result c is a vector of length m+1 containing
the polynomial coefficients in descending powers:
p(x) = c[1]*x^n +
2004 Aug 09
0
returns the value of a polynomial of degree n evaluated a t x.
Try something like:
install.packages("polynom")
library(polynom)
predict(polynomial(rev(p)), x)
HTH,
Andy
> From: McClatchie, Sam (PIRSA-SARDI)
>
> > Background:
> > OS: Linux Mandrake 9.1
> > release: R 1.9.0
> > editor: Xemacs 21.4
> > frontend: ESS 5.1.23
> > ---------------------------------
> >
> > Colleagues
> >