quantSheets()
is based on the work of Sabine
Schnabe and Paul Eiler (see references below). The estimation of the quantile curves
is done simultaneously by also smoothing in the direction of y as well as x. This avoids (but do not eliminate completely) the problem of crossing quantiles.quantSheets(y, x, x.lambda = 1, p.lambda = 1, data = NULL,
cent = 100 * pnorm((-4:4) * 2/3),
control = quantSheets.control(...), print = TRUE, ...)quantSheets.control(x.inter = 10, p.inter = 10, degree = 3, logit = FALSE,
order = 2, kappa = 0, n.cyc = 100, c.crit = 1e-05, plot = TRUE,
power = NULL, ...)
findPower(y, x, data = NULL, lim.trans = c(0, 1.5), prof = FALSE,
k = 2, c.crit = 0.01, step = 0.1)
z.scoresQS(object, y, x, plot = FALSE, tol = NULL)
logit(p)
instead of p
(probabilities) for the y-axisfindPower()
optim()
to the parameter
the power transformationprof
of
findPower()
is TRUEquantSheets
objectflexDist()
functionquantSheets()
a quantSheets
object is returned having the following methods:
print()
, fitted()
, predict()
and resid()
. Using findPower()
a single values of the power parameter is returned.
Using z.scoresQS
a vector of z-scores is returned.
The disadvantages of quantile sheets comes from the fact that like all non-parametric techniques do not have a goodness of fit measure to change how good is the models and the residuals based diagnostics are not existence since it is difficult to define residuals in this set up.
In this implementation we do provide residuals by using the flexDist()
function from package flexDist()
is doing.
As a word of caution, such a construct is based on several assumptions and depends on
several smoothing parameters. Treat those residuals with caution.
The same caution should apply to the function z.scoresQS()
.
Schnabel, S. K and Eilers, P. H. C.(2013) Simultaneous estimation of quantile curves using quantile sheets, AStA Advances in Statistical Analysis, 97, 1, pp 77-87, Springer.
Schnabel, S. K and Eilers, P. H. (2013) A location-scale model for non-crossing expectile curves, Stat, 2, 1, pp 171-183.
lms
: for a parametric equivalent results.data(abdom)
m1 <- quantSheets(y,x, data=abdom)
head(fitted(m1))
p1 <- predict(m1, newdata=c(20,30,40))
matpoints(c(20,30,40), p1)
z.scoresQS(m1,y=c(150, 300),x=c(20, 30) )
# If we needed a power transformation not appropriate for this data
findPower(y,x, data=abdom)
Run the code above in your browser using DataLab