predict.endorse {endorse} | R Documentation |
Predict Method for the Measurement Model of Political Support
Description
Function to calculate predictions from a measurement model fitted to an endorsement experiment data.
Usage
## S3 method for class 'endorse'
predict(object, newdata, type = c("prob.support",
"linear.s"), standardize = TRUE, ...)
Arguments
object |
a fitted object of class inheriting from |
newdata |
an optional data frame containing data that will be used to make predictions from. If omitted, the data used to fit the regression are used. |
type |
the type of prediction required. The default is on the
scale of the predicted probability of positive support; the
alternative |
standardize |
logical switch indicating if the predicted values on
the scale of |
... |
further arguments to be passed to or from other methods. |
Details
predict.endorse
produces predicted support for political actors
from a fitted "endorse"
object. If newdata
is omitted
the predictions are based on the date used for the fit. Setting
type
specifies the type of predictions. The default is
"prob.support"
, in which case the function computes the average
predicted probability of positive support:
for each political group . If
type
is set to be
"linear.s"
, the output is the predicted mean of support
parameters:
If the logical standardize
is TRUE
, the predicted mean
of support is standardized by dividing by .
Value
A "mcmc"
object for predicted values.
Author(s)
Yuki Shiraito, Department of Political Science, University of Michigan shiraito@umich.edu.
See Also
endorse
for model fitting