newresponse | R Documentation |
Generic function and methods for computing (randomized) quantile residuals.
newresponse(object, ...) ## Default S3 method: newresponse(object, newdata, na.action = na.pass, ...) ## S3 method for class 'glm' newresponse(object, newdata, na.action = na.pass, ...)
object |
a fitted model object. For the |
... |
further parameters passed to methods. |
newdata |
optionally, a data frame in which to look for variables with which to predict. If omitted, the original observations are used. |
na.action |
function determining what should be done with missing
values in |
This is a convenience function to accompany procast
, e.g., for
computing predicted probabilities at the observed responses (also known as
the probability integral transform, PIT).
A vector of new responses.
terms
, model.frame
## linear regression models (homoscedastic Gaussian response) m <- lm(dist ~ speed, data = cars) newresponse(m) newresponse(m, newdata = cars[1:3, ])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.