Learn R Programming

PhaseGMM (version 0.1.0)

predict.eiv_mlr: Predictions from an Errors-in-Variables Linear Model

Description

Generates fitted values or confidence intervals for new observations using plug-in estimates. Measurement error is not corrected for new data.

Usage

# S3 method for eiv_mlr
predict(
  object,
  newdata = NULL,
  interval = c("none", "confidence"),
  level = 0.95,
  ...
)

Value

A numeric vector of predictions, or a matrix with columns

fit, lwr, and upr if intervals are requested.

Arguments

object

An object of class "eiv_mlr".

newdata

Optional data frame containing covariates. If omitted, predictions are returned for the training data.

interval

Type of interval to compute: "none" or "confidence".

level

Confidence level for intervals.

...

Not used.