View source: R/calSecDerNatSpline.R
calSecDerNatSpline | R Documentation |
Natural Spline Basis and the Regularization Matrix A_m
calSecDerNatSpline(grd)
grd |
A vector of length p indicating the grd values where the spline functions are evaluated. |
calSecDerNatSpline
calculates evaluated natural cubic splines
and the matrix A_m
as described in Crambes, Kneip and Sarda
(2016).
calSecDerNatSpline
calculates an evaluated natural cubic
spline basis corresponding to grd
and a p \times p matrix
used for regularization in the smoothing splines estimator for the
functional linear model (Crambes, Kneip and Sarda,2016). A_m
is
composed of a non-classical projection matrix and the classical
regularization matrix of squared second derivatives.
A list with entries
A_m |
The p \times p matrix A as described in (Crambes, Kneip and Sarda, 2016) |
X_B |
A p \times p matrix of natural cubic spline basis evaluated at |
Dominik Liebl, Stefan Rameseder and Christoph Rust
Crambes, C., Kneip, A., Sarda, P. (2009) Smoothing Splines Estimators for Functional Linear Regression. The Annals of Statistics, 37(1), 35-72.
FunRegPoI
## Not run: library(FunRegPoI) ## Define Parameters for Simulation DGP_name <- "Easy" k_seq <- c(1,seq(2, 60, 4)) error_sd <- 0.125 N <- 500 p <- 300 domain <- c(0,1) grd <- seq(domain[1],domain[2],length.out = p) set.seed(1) ## simulate some data: PoISim <- FunRegPoISim(N = N , grd, DGP = DGP_name , error_sd = error_sd) NaturalSplines <- calSecDerNatSpline(grd) # PESES EstPeses <- FunRegPoI(Y = PoISim$Y , X_mat = PoISim$X , grd, estimator = "PESES", k_seq = k_seq , A_m = NaturalSplines$A_m , X_B = NaturalSplines$X_B) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.