Learn R Programming

MIIVsem (version 0.1)

miivs: Model-implied instrumental variable (MIIV) search

Description

A key step in the MIIV-2SLS approach is to transform the SEM by replacing the latent variables with their scaling indicators minus their errors. Upon substitution the SEM is transformed from a model with latent variables to one in observed variables with composite errors. The miivs function automatically makes this transformation.

Usage

miivs(model)

Arguments

model
A model specified using lavaan model syntax. See the model argument within the lavaanify function for more information.

Value

  • eqns

    modeqns

Details

  • LHSThe "dependent" variable.
  • RHSThe right hand side variables of the transformed equation.
  • Composite DisturbanceElements of the composite errors in the transformed equation.
  • MIIVsThe model implied instrumental variables for each equation.

References

Bollen, K. A. and D. J. Bauer. 2004. Automating the Selection of Model-Implied Instrumental Variables. Sociological Methods and Research, 32, 425-52.

Examples

Run this code
bollen1989a_model <- '

   Eta1 =~ y1 + y2  + y3  + y4
   Eta2 =~ y5 + y6  + y7  + y8
   Xi1  =~ x1 + x2 + x3

   Eta1 ~ Xi1
   Eta2 ~ Xi1
   Eta2 ~ Eta1

   y1   ~~ y5
   y2   ~~ y4
   y2   ~~ y6
   y3   ~~ y7
   y4   ~~ y8
   y6   ~~ y8
 '

 miivs(bollen1989a_model)

Run the code above in your browser using DataLab