predict.tps {funfits}R Documentation

Evaluation of thin plate spline surface.

Usage

predict.tps(out, x, lambda, derivative=0, model=NA)

Arguments

out Fitted tps object.
x Matrix of x values on which to evaluate the thin plate spline surface. If omitted, out$x will be used.
lambda Smoothing parameter. If omitted, out$lambda will be used.
derivative Derivative of function is returned if derivative=1. Generic argument that may be used to pass a different lambda.

Value

Vector of predicted responses. If derivative=1 a vector of derivatives or a matrix of partial derivatives is returned.

See Also

tps, predict.surface

Examples

tps(ozone$x,ozone$y) -> fit                 # tps fit
cbind(seq(87,89,,10),seq(40,42,,10)) -> x   # new x matrix
predict(fit,x) -> out                       # evaluate fit at x


[Package Contents]