Leave one-subject cross-validation score for spline fit
CVspline(Xvec, Yvec, ID, nKnots, Degree, Wt)
Xvec, Yvec
: numeric vectors of data values, Xvec and Yvec must have the same length.ID
: subject ID of the data valuenKnots
: number of equally-spaced knotsDegree
: degree of polynomial splinesWt
: a weight vector. For longitudinal data, Wt=1/N corresponds to measurement uniform weight and Wt=1/(nni) corresponds subject uniform weight.Wu, C.O. and Tian, X. Nonparametric Models for Longitudinal Data. Chapman & Hall/CRC. To appear.