regime: Spatial Regime Model

Description Usage Arguments Details Author(s) References Examples

View source: R/regime.R

Description

Estimates the stability of a given model across a set of user-specified regimes.

Usage

1
2
3
4
5
6
7
8
9
regime(
  restrict,
  group,
  data,
  var_int = FALSE,
  lw_lst = NULL,
  error = TRUE,
  robust = FALSE
)

Arguments

restrict

lm-style formula for the restricted regression.

group

RHS formula depicting only the factor variable used to identify regimes (i.e. no dependent variable needed).

data

model data frame.

var_int

a logical value indicating whether or not to include group-specific intercepts in the restricted model. Default is FALSE

lw_lst

a list of listw objects corresponding to the levels of the factor used to define regimes. The default value is NULL.

error

a logical value indicating type of spatial regime model to use when !is.null(lw_lst). A value of TRUE produces a spatial error model, while a value of FALSE produces a spatial lag model. #' @param robust a logical value indicating whether to use HC3 standard errors.

...

additional arguments to be passed to the model-fitting routine.

Details

regime compares the fit of a restricted or global model in which a given set of coefficients are treated as fixed to the fit of an unrestricted or local model in which the coefficients in question are allowed to vary across a set of user-specified regimes. Regime models are specified using two formulas, the first of which depicts the global model, the second of which depicts the variable used to specify regimes. Spatial regime models are estimated using the errorsarlm and lagsarlm routines available as part of the spreg package. The resulting test is ultimately carried out using the anova command which, in the case of non-spatial regime models, results in the standard F-test. In contrast, the use of the anova command in the context of likelihood-based models such as errorsarlm and lagsarlm results in a likelihood ratio test. The null model can be adjusted to allow for regime-specific intercepts.

Author(s)

Adam Slez aslez@virginia.edu

References

Anselin, L. 1988. Spatial Econometrics: Methods and Models. Durdrecht: Kluwer Academic Publishers, pp. 123-124.

Chow, G. 1960. "Tests of Equality Between Sets of Coefficients in Two Linear Regressions." Econometrica 28:591-605.

Examples

1
2
3
4
data(nat60_sf)
reg_mod60 <- regime(HR60 ~ RD60 + PS60 + MA60 + DV60 + UE60, 
     group = ~ SOUTH, data = nat60_sf)
reg_mod60

aslez/spRegime documentation built on April 16, 2020, 9:51 a.m.