make.knots: Locate the knots in m-space.

View source: R/make.knots.R

make.knotsR Documentation

Locate the knots in m-space.

Description

Setup knots for spline models.

Usage

make.knots(x, method, splineArgs)

Arguments

x

"matrix". n-by-m. Covariates matrix *without* intercept.

method

"character". Method to be use in the knots locating method. Currently value are "k-means", "mahalanobis-eball" which came from Villani et al (2009) and "es" for equal spaced sample quantile with single covariate and "random".

n.knots

"integer". Number of knots used.

args

"list". Other arguments need to pass to the function w.r.t different "method". When method is "mahalanobis-eball", you need to provide: args$RadiusShrink: "numeric", the radus shrinkage for the ball.

Details

This function can be used in the initial values for splines

Value

"list". A list with knots locations for given numbers of knots.

Note

First version: Wed Mar 10 14:03:31 CET 2010; Current: Thu Sep 16 13:56:37 CEST 2010.

Author(s)

Feng Li, Department of Statistics, Stockholm University, Sweden.

References

Appendix C. in Villani et al (2009)


thiyangt/fformpp documentation built on Jan. 5, 2024, 5:44 a.m.