computeH: Compute H values

View source: R/computeH.R

computeHR Documentation

Compute H values

Description

Computes H values (cross-sectional variance) according to the clustering algorithm by Phillips and Sul (2007, 2009)

Usage

computeH(X, quantity = "H", id)

Arguments

X

matrix or dataframe containing data (preferably filtered, in order to remove business cycles)

quantity

string indicating the quantity that should be returned. The options are "H", the default, only the vector of cross-sectional variance is returned; "h", only the matrix of transition path h is return; "both", a list containing both h and H is returned.

id

optional; row index of regions for which H values are to be computed; if missing, all regions are used

Details

The cross sectional variation H(it) is computed as the quadratic distance measure for the panel from the common limit and under the hypothesis of the model should converge to zero as t tends towards infinity:

H(t) = 1/N ∑ [h(it)-1]^2 --> 0 as t -> infinity

where

h(it) = N log[y(it)] / ∑ log[y(it)]

Value

A numeric vector, a matrix or a list, depending on the value of quantity

References

Phillips, P. C.; Sul, D., 2007. Transition modeling and econometric convergence tests. Econometrica 75 (6), 1771-1855.

Phillips, P. C.; Sul, D., 2009. Economic transition and growth. Journal of Applied Econometrics 24 (7), 1153-1185.

Examples

data("filteredGDP")

h <- computeH(filteredGDP[,-1], quantity="h")
H <- computeH(filteredGDP[,-1], quantity="H")
b <- computeH(filteredGDP[,-1], quantity="both")



ConvergenceClubs documentation built on June 14, 2022, 1:06 a.m.