Skip to content

Run panel-data heteroscedasticity tests

Source: man/runPanelTests.Rd ยท Help: ?runPanelTests

Breusch-Pagan LM and Pesaran CD tests for panel models.

Usage

runPanelTests(model, data, id, time = NULL,
          tests = c("bp_random", "pesaran"))

Arguments

model
A fitted lm object.
data
Data frame used to fit model.
id
Column identifying individuals.
time
Column identifying time periods for the Pesaran test.
tests
Character vector of test names.

Value

A named list of htest objects.

See also

runTimeSeriesTests

Examples

 df <- data.frame(id = rep(1:3, each = 4), time = rep(1:4, 3),
                  x = runif(12), y = rnorm(12))
 m <- lm(y ~ x, data = df)
 runPanelTests(m, df, id = "id", time = "time")