Re: [R] Fitting spline using Pspline

2011-05-29 Thread Ravi Varadhan
= glkerns(x, y) lines(fit3$x.out,fit3$est, col=4) Ravi. From: r-help-boun...@r-project.org [r-help-boun...@r-project.org] On Behalf Of guy33 [david.res...@magd.ox.ac.uk] Sent: Sunday, May 29, 2011 6:28 PM To: r-help@r-project.org Subject: Re: [R] Fitting sp

Re: [R] Fitting spline using Pspline

2011-05-29 Thread guy33
Ravi, Thanks so much! You're right, smooth.spline does work on larger n. Although, for some reason it's results are different (slightly less good?, but I'm not sure). For example, on the simple doppler function below, sm.spline seems to be closer to the true function than smooth.spline: x=arra

Re: [R] Fitting spline using Pspline

2011-05-29 Thread Ravi Varadhan
0 PM To: r-help@r-project.org Subject: [R] Fitting spline using Pspline Hey all, I seem to be having trouble fitting a spline to a large set of data using PSpline. It seems to work fine for a data set of size n=4476, but not for anything larger (say, n=4477). For example:

[R] Fitting spline using Pspline

2011-05-29 Thread guy33
Hey all, I seem to be having trouble fitting a spline to a large set of data using PSpline. It seems to work fine for a data set of size n=4476, but not for anything larger (say, n=4477). For example: THIS WORKS: - random = array(0,c(4476,2)) random[,1] = runif(4476,