plotSEMM_setup: Set up function for plotSEMM

Description Usage Arguments Details Author(s) References See Also Examples

Description

Takes user input generated from SEMM software such as Mplus (Muthen & Muthen, 2007), Mx (Neale, Boker, Xie & Maes, 2004) or MECOSA (Arminger, Wittenberg, & Schepers, 1996) in Gauss and generates model predicted data for processing in graphing functions plotSEMM_contour and plotSEMM_probability. Reterns a data.frame to be passed to other functions in the package.

Usage

1
plotSEMM_setup(pi, alpha1, alpha2, beta21, psi11, psi22, points = 50)

Arguments

pi

Vector: K marginal class probabilities.

alpha1

Vector: K means of the latent predictor.

alpha2

Vector: K inercepts slopes from the within-class regression of the latent outcome on the latent predictor.

beta21

Vector: K slopes from the within-class regression of the latent outcome on the latent predictor.

psi11

Vector: K within-class variances of the latent predictor.

psi22

Vector: K within-class variances of the latent outcome.

points

number of points to use. Default is 50

Details

All the parameter estimates required by the arguments are generated from software with the capability of estimating SEMMs.

Author(s)

Bethany Kok and Phil Chalmers rphilip.chalmers@gmail.com

References

Pek, J. & Chalmers, R. P. (2015). Diagnosing Nonlinearity With Confidence Envelopes for a Semiparametric Approach to Modeling Bivariate Nonlinear Relations Among Latent Variables. Structural Equation Modeling, 22, 288-293. doi: 10.1080/10705511.2014.937790

Pek, J., Chalmers, R. P., Kok B. E., & Losardo, D. (2015). Visualizing Confidence Bands for Semiparametrically Estimated Nonlinear Relations among Latent Variables. Journal of Educational and Behavioral Statistics, 40, 402-423. doi: 10.3102/1076998615589129

See Also

plotSEMM_contour,plotSEMM_probability

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
## Not run: 
# 2 class empirical example on positive emotions and heuristic processing
# in Pek, Sterba, Kok & Bauer (2009)
pi <- c(0.602, 0.398)

alpha1 <- c(3.529, 2.317)

alpha2 <- c(0.02, 0.336)

beta21 <- c(0.152, 0.053)

psi11 <- c(0.265, 0.265)

psi22 <- c(0.023, 0.023)

plotobj <- plotSEMM_setup(pi, alpha1, alpha2, beta21, psi11, psi22)

## End(Not run)

Example output

Loading required package: plyr
Loading required package: shiny
Warning messages:
1: In seq_len(length.out - 2L) * by :
  Recycling array of length 1 in vector-array arithmetic is deprecated.
  Use c() or as.vector() instead.

2: In from + seq_len(length.out - 2L) * by :
  Recycling array of length 1 in array-vector arithmetic is deprecated.
  Use c() or as.vector() instead.

3: In seq_len(length.out - 2L) * by :
  Recycling array of length 1 in vector-array arithmetic is deprecated.
  Use c() or as.vector() instead.

4: In from + seq_len(length.out - 2L) * by :
  Recycling array of length 1 in array-vector arithmetic is deprecated.
  Use c() or as.vector() instead.

plotSEMM documentation built on May 1, 2019, 8:07 p.m.