You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you run questionnaire_gen() with family="gaussian", lsasim will generate multinomial variables. You can also add full_output=TRUE to get the variance-covariance matrix:
bgr<- questionnaire_gen(
n_obs=N, cat_prop=c_prop, cor_matrix=d, n_vars=6, theta=TRUE,
family="gaussian", full_output=TRUE# new additions to your code
)
bgr_dt<-bgr$bgcovariances<-bgr$linear_regression$vcov_YXW
I'm trying to think if it is possible for the user to explicitly pass this YXW variance matrix, but I don't think it is: they can only pass the YXZ matrix, and then W is calculated as a multinomial equivalent of the Normally-distributed Zs.
In summary, the current version of lsasim generates correlated multinomial variables, but I reckon the user doesn't have explicit control over those values.
Dear lsasim team,
In the following example, I can generate correlated ordinal background variables
However, this function doesn't allow us to generate correlated multinomial variables, such as "race".
How can we achieve this?
Thank you,
Sinan
The text was updated successfully, but these errors were encountered: