# \donttest{
# note: iter = 250 for demonstrative purposes
# data
Y <- BGGM::ptsd
#########################
###### continuous #######
#########################
# estimate the model
fit <- estimate(Y, iter = 250,
progress = FALSE)
# compute correlations
cors <- pcor_to_cor(fit)
#########################
###### ordinal #########
#########################
# first level must be 1 !
Y <- Y + 1
# estimate the model
fit <- estimate(Y, type = "ordinal",
iter = 250,
progress = FALSE)
# compute correlations
cors <- pcor_to_cor(fit)
#########################
####### mixed ######
#########################
# rank based correlations
# estimate the model
fit <- estimate(Y, type = "mixed",
iter = 250,
progress = FALSE)
# compute correlations
cors <- pcor_to_cor(fit)
# }
Run the code above in your browser using DataLab