Skip to content

evaluating derivative matrices of spline functions

2 messages · Vassily Shvets, Spencer Graves

#
Hello,
I've noticed that SPLUS has a function for evaluating the derivative matrices of splines.
I've also noticed that there's a function in R for evaluating matrices from smooth.spline;
maybe someone knows if something has been written to evaluate matrices from 'smooth.basis'?
regards,
s
#
I don't know about "smooth.spline", but the "fda" package 
includes "deriv.fd".  It also includes "eval.fd" and "predict.fd".  If 
you only want a first derivative, then differentiating a standard cubic 
spline may be adequate.  However, the first derivative of a cubic spline 
is a quadratic spline, the second derivative is a linear spline, and the 
third derivative is a step function.  The "fda" package provides more 
alternative basis sets than the standard cubic splines, and may give you 
results more to your liking.


       Hope this helps.
       Spencer


p.s.  Full disclosure:  I'm the third author on the Springer "Use R!" 
book on "Functional Data Analysis with R and Matlab".  I was the R 
expert on the team that produced that book.  The lead author, Jim 
Ramsay, invented "functional data analysis" as a generalization of 
spline smoothing to (a) bases other than the standard cubic b-splines 
and (b) penalty functions other than the standard integral of the square 
of the second derivative.
On 2/24/2012 12:33 PM, Vassily Shvets wrote: