Title

phmoment -- Moments Estimation for Heterogeneous Panel Data

Syntax

phmoment panelvar [if] [in][, options]

Order
acov_order(#) set order of the autocovariance; default is 0.

acor_order(#) set order of the autocorrelation; default is 1.

boot(#) set number of bootstrap replication; default is 200.

Method
method(string) string must be one of three estimation methods "naive", "hpj", "toj".

panelvar must be xtset and strongly balanced.

Description

phmoment performs estimation of 9 moments(1.mean of mean, 2.mean of autocovariance, 3.mean of autocorrelation,
4.variance of mean, 5.variance of autocovariance, 6 variance of autocorrelation,
7.correlation between mean and autocovariance, 8.correlation between mean and autocorrelation, and 9.correlation between autocovariance and autocorrelation)
when the panel data exhibits heterogeneity across its cross-sectional units.

Dependencies

phmoment requires the moremata
package. Type

. ssc describe moremata

Options

Order

acov_order non-negative integer k for the order of autocovariance. The default is 0.

acor_order positive integer k for the order of autocorrelation. The default is 1.

boot positive interger k for the number of bootstrap replication. The default is 200.

Method

method(strings:string) specifies how the densities of moments are estimated.
"naive" stands for naive estimation without bias-correction, "hpj" for half panel jackknife and "toj" for third order jackknife.

Stored results

phmoment stores the following in e():

Matrices

e(ci) 95% confidence intervals for the moments based on cross-sectional bootstrap.

e(se) standard errors for the estimators based on cross-sectional bootstrap.

e(est) estimates for the moments.

All these are ordered by 1. mean of mean, 2. mean of autocovariance, 3. mean of autocorrelation, 4. variance of mean, 5. variance of autocovariance, 6. variance of autocorrelation,
7. correlation between mean and autocovariance, 8. correlation between mean and autocorrelation, and 9. correlation between autocovariance and autocorrelation.

Examples: moments estimation

Setup

. webuse pig

. xtset id week

Estimate the moments of the variable weight about mean, autocovariance of order 2 and autocorrelation of order 3 using Half Panel Jackknife with 300 bootstrap replications.

. phmoment weight, method("hpj") boot(300) acov_order(2) acor_order(3)

Reference

Ryo Okui. and Takahide Yanagi. 2019.
Panel Data Analysis with Heterogeneous Dynamics.
Journal of Econometrics.