View source: R/glm_hP_methods.R
| predict.glm_hP | R Documentation | 
Obtains predictions from a fitted "glm_hP" object.
## S3 method for class 'glm_hP'
predict(object, newdata = NULL, type = c("link", "response"), ...)
object | 
 a fitted object of class inheriting from   | 
newdata | 
 optionally, a data frame in which to look for variables with which to predict. If omitted, the fitted linear predictors are used.  | 
type | 
 the type of prediction required. The default is on the scale of
the linear predictors; the alternative   | 
... | 
 further arguments passed to or from other methods.  | 
A vector with the prediction means.
data(Bids)
## Fit a hype-Poisson model
Bids$size.sq <- Bids$size ^ 2
fit <- glm.hP(formula.mu = numbids ~ leglrest + rearest + finrest +
              whtknght + bidprem + insthold + size + size.sq + regulatn,
              formula.gamma = numbids ~ 1, data = Bids)
## As the newdata parameter is not used the fitted values are obtained
predict(fit, type = "response")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.