qresiduals | R Documentation |
Generic function and methods for computing (randomized) quantile residuals.
qresiduals(object, ...) ## Default S3 method: qresiduals(object, scale = "normal", ...)
object |
an object. For the |
... |
further parameters passed to |
scale |
On which scale should the PIT residuals be shown; on the probability scale
( |
(Randomized) quantile residuals are simply the theoretical standard normal quantiles evaluated at the PIT residuals as suggested by Dunn and Smyth (1996). For regression models with a continuous response distribution these are exact; for discrete distributions, PIT residuals are drawn from the range of probabilities corresponding to each observation, hence quantile residuals must be random as well.
The default qresiduals
method calls pitresiduals
with
scale
equal "normal"
, as employed in normal Q-Q
plots (qqrplot
).
A vector or matrix of quantile residuals.
Note that there is also a qresiduals
function
in the statmod package that is not generic and always returns a single
random quantile residual.
Dunn KP, Smyth GK (1996). “Randomized Quantile Residuals.” Journal of Computational and Graphical Statistics, 5(3), 236–244. doi: 10.2307/1390802
pitresiduals
, qnorm
, qqrplot
## linear regression models (homoscedastic Gaussian response) m <- lm(dist ~ speed, data = cars) qresiduals(m)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.