precompute {hero} | R Documentation |
Precompute objects
Description
This function is an internal function to compute objects needed for fast implementation of the sandwich smoother. It is meant to be an internal function, so use this at your own risk.
Usage
precompute(B, P, m)
Arguments
B |
A matrix of basis functions |
P |
A penalty matrix |
m |
Difference order of P-spline |
Value
A list of needed objects
Examples
object = bspline(nbasis = 10)
# sequence to evaluate
evalarg = seq(0, 1, len = 11)
# penalty matrix
D = diffpen(object)
P = Matrix::crossprod(D)
B = predict(object, evalarg)
stuff = precompute(B, P, m = 2)
[Package hero version 0.6 Index]