*!version 1.1.0 07/08/2020
help index

Title

icw_index -- aggregates the variables included in the varlist into an index.

Syntax

index
varlist , option

Main
generate(name) gen a new variable that contains the index.

Description

icw_index creates an index from a list of variables included in varlist. icw_index stands for inverse covariance index and follows Anderson (2008). Importantly, variables in varlist must be standardized and centered before running the command.
Following Anderson, the index is calculated from the inverse covariance matrix. As suggested, we use the inverse covariance matrix of non-missing observations.
In case of missing data, we calculate for each pattern of missing observation a specific covariance matrix.

Beware that if varlist contains lots of missing values (or rather if each observation has a specific pattern of missing values) the code can take a long time as the number of potential combinaison can be exponential.
For instance, an index composed of 10 variables has a maximum number of combinations equals to 1023. Typically when your varlist is composed of more than 10 variables it could be useful to verify if your missing values are equally spread out (if every observation has the same number of missing values) or if each observation have a unique missing pattern. In the latter case, the code will take a long time. A warning will be displayed if more than 1000 matrix needs to be inverted.

Examples

Create an index GPA from grades in math economics and biology:

. icw_index math economics and biology, gen(GPA)

Author

Adrien Bouguen, Santa Clara University

Tereza Varejkova, University of Maryland

References

Michael L. Anderson Multiple Inference and Gender Differences in the Effects of Early Intervention: AReevaluation of the Abecedarian, Perry Preschool, and Early Training Projects Journal of the American Statistical Association, Vol. 103, No. 484 (Dec., 2008), pp.1481-1495