rqss
object produced by rqss()
and plots
the component smooth functions that make up the ANOVA decomposition.
Since the components "omit the intercept" the estimated intercept is added back
in -- this facilitates the comparison of quantile fits particularly.
For models with a partial linear component or several qss
components
it may be preferable to plot the output of predict.rqss
.
Note that these functions are intended to plot rqss
objects only, attempting
to plot {summary.rqss} objects just generates a warning message.## S3 method for class 'rqss':
plot(x, rug = TRUE, jit = TRUE, bands = NULL, coverage = 0.95,
add = FALSE, shade = TRUE, select = NULL, pages = 0, titles = NULL, \dots)
## S3 method for class 'qss1':
plot(x, rug = TRUE, jit = TRUE, add = FALSE, \dots)
## S3 method for class 'qss2':
plot(x, render = "contour", ncol = 100, zcol = NULL, \dots)
## S3 method for class 'summary.rqss':
plot(x, ...)
rqss
object produced by rqss()
."contour"
(default) or "rgl"
. The latter
requires package render = "rgl"
: number of colors and
z values for color construction."qss1"
the "add = TRUE"
can be used to overplot the fit on a
scatterplot. When there are multiple pages required "par(ask = TRUE)"
is turned on so that the plots may be examined sequentially. If bands != NULL
then a list with three components for each qss component is returned (invisibly):bands = "both"
then this is a matrix with two columnsbands = "both"
then this is a matrix with two columnsbands == "uniform"
then the bands are uniform bands based on the
Hotelling (1939) tube approach. See also Naiman (1986),
Johansen and Johnstone (1990), Sun and Loader (1994),
and Krivobokova, Kneib, and Claeskens (2009), in particular the computation of
the "tube length" is based on the last of these references. If bands
is non null, and not "uniform" then pointwise bands are returned.
Since bands for bivariate components are not (yet) supported, if requested
such components will be returned as NULL
.[2] Johansen, S., and I.M. Johnstone (1990): ``Hotelling's Theorem on the Volume of Tubes: Some Illustrations in Simultaneous Inference and Data Analysis,'' The Annals of Statistics, 18, 652--684.
[3] Naiman, D. (1986) Conservative confidence bands in curvilinear regression, The Annals of Statistics, 14, 896--906.
[4] Sun, J. and C.R. Loader, (1994) Simultaneous confidence bands for linear regression and smoothing, The Annals of Statistics, 22, 1328--1345.
[5] Krivobokova, T., T. Kneib, and G. Claeskens (2009) Simultaneous Confidence Bands for Penalized Spline Estimators, preprint.
[6] Koenker, R. (2010) Additive Models for Quantile Regression: Model Selection and Confidence Bandaids, preprint.
rqss
n <- 200
x <- sort(rchisq(n,4))
z <- x + rnorm(n)
y <- log(x)+ .1*(log(x))^2 + log(x)*rnorm(n)/4 + z
plot(x,y-z)
fN <- rqss(y~qss(x,constraint="N")+z)
plot(fN)
fI <- rqss(y~qss(x,constraint="I")+z)
plot(fI, col="blue")
fCI <- rqss(y~qss(x,constraint="CI")+z)
plot(fCI, col="red")
## A bivariate example
data(CobarOre)
fCO <- rqss(z~qss(cbind(x,y),lambda=.08), data = CobarOre)
plot(fCO)
Run the code above in your browser using DataLab