predict.pmpp: Compute forecasts with a PMPP model

Description Usage Arguments Value Author(s) Examples

View source: R/pmpp_predict.R

Description

Compute forecasts with a PMPP model

Usage

1
2
## S3 method for class 'pmpp'
predict(object, fframe = NULL, iter = NULL, ...)

Arguments

object

an object of class pmpp()

fframe

data.frame with the same columns as input data to model, but with empty rows added to each cross-sectional unit, as created by create_fframe()

iter

iterating constant, to be used in a loop when extraction from call is needed

...

other arguments passed to the method

Value

A data.frame with predicted and true values.

Author(s)

Michal Oleszak

Examples

1
2
3
4
5
data(EmplUK, package = "plm")
EmplUK <- dplyr::filter(EmplUK, year %in% c(1978, 1979, 1980, 1981, 1982))
pmpp_model <- pmpp(dep_var = "emp", data = EmplUK)
my_fframe <- create_fframe(EmplUK, 1983:1985)
prediction <- predict(pmpp_model, my_fframe)

veneficusnl/pmpp documentation built on Oct. 16, 2019, 11:22 a.m.