Convert Smoothing Parameter to Degrees of Freedom

Convert Smoothing Parameter to Degrees of Freedom

DESCRIPTION:

The degree of roughness of an estimated function is controlled by a smoothing parameter lambda that directly multiplies the penalty. However, it can be difficult to interpret or choose this value, and it is often easier to determine the roughness by choosing a value that is equivalent of the degrees of freedom used by the smoothing procedure. This function converts a multipler lambda into a degrees of freedom value.

USAGE:

lambda2df(argvals, basisfd, wtvec=rep(1, n), Lfd=NULL, lambda=0)

REQUIRED ARGUMENTS:

argvals
Argument values associated with the values to be smoothed.
basisfd
A basis object.

OPTIONAL ARGUMENTS:

wtvec
A vector of weights for the data to be smoothed.
Lfd
Either a nonnegative integer or a linear differential operator object.
lambda
The smoothing parameter to be converted.

VALUE:

The equivalent degrees of freedom value.

DETAILS:

The conversion requires a one-dimensional optimization and may be therefore computationally intensive.

REFERENCES:

EXAMPLES: