sem_appl {CIEE} | R Documentation |
Structural equation modeling approach
Description
Function which uses the sem
function in the
lavaan
package to fit the model
in order to obtain point and standard error estimates
of the parameters
for the GLM setting.
See the vignette for more details.
Usage
sem_appl(Y = NULL, X = NULL, K = NULL, L = NULL)
Arguments
Y |
Numeric input vector for the primary outcome. |
X |
Numeric input vector for the exposure variable. |
K |
Numeric input vector for the intermediate outcome. |
L |
Numeric input vector for the observed confounding factor. |
Value
Returns a list with point estimates of the parameters
(point_estimates
), standard error estimates
(SE_estimates
) and p-values from large-sample
Wald-type tests (pvalues
).
Examples
dat <- generate_data(setting = "GLM")
sem_appl(Y = dat$Y, X = dat$X, K = dat$K, L = dat$L)
[Package CIEE version 0.1.1 Index]