Description Usage Arguments Value References Examples
Fits a penalized spline to the supplied data.
1 2 |
x, y |
vectors giving the coordinates of the points in the scatter plot. Missing values are deleted. |
family |
a description of the error distribution to be used in the model. By default the Student-t distribution with 4 degrees of freedom is considered. |
nseg |
number of segments used to divide the domain, this information is required to construct the sequence of knots. Default value is 20. |
deg |
the degree of the spline transformation. Must be a nonnegative integer. The default value is 3. The polynomial degree should be a small integer, usually 0, 1, 2, or 3. Larger values are rarely useful. |
ord |
the order of the roughness penalty. Default value is 2. |
lambda |
specifies the smoothing parameter for the fit. It is fixed if |
method |
the method for choosing the smoothing parameter |
ngrid |
number of elements in the grid used to compute the smoother. Only required to plot the fitted P-spline. |
control |
a list of control values for the estimation algorithm to replace
the default values returned by the function |
an object of class heavyPS
representing the fitted model. Generic
functions print
and summary
, show the results of the fit.
The following components must be included in a legitimate heavyPS
object.
call |
a list containing an image of the |
design |
a list containing the B-spline basis matrix, the triangular factor of the penalty matrix and a numeric vector of knot positions with non-decreasing values. |
method |
one of "GCV" or "none", depending on the fitting criterion used. |
family |
the |
coefficients |
final estimate of the coefficients vector. |
scale |
final scale estimate of the random error. |
lambda |
estimated smoothing parameter for the model (if requested). |
fitted.values |
fitted model predictions of expected value for each datum. |
residuals |
the residuals for the fitted model. |
plogLik |
the penalized log-likelihood at convergence. |
edf |
the effective number of parameters. |
gcv |
the minimized smoothing parameter selection score (weighted GCV). |
pen |
the penalty term at convergence. |
numIter |
the number of iterations used in the iterative algorithm. |
weights |
estimated weights corresponding to the assumed heavy-tailed distribution. |
distances |
squared of scaled residuals. |
xgrid |
grid of x-values used to fit the P-spline. |
ygrid |
estimated curve on the x-grid, required to plot the fitted P-spline. |
shape |
estimated shape parameters, only available if requested. |
Eilers, P.H.C., and Marx, B.D. (1996). Flexible smoothing using B-splines and penalties (with discussion). Statistical Science 11, 89-121.
Osorio, F. (2016). Influence diagnostics for robust P-splines using scale mixture of normal distributions. Annals of the Institute of Statistical Mathematics 68, 589-619.
1 2 3 4 5 6 7 8 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.