Skip to content

Generating multinomial background variables #41

@Sinan-Yavuz

Description

@Sinan-Yavuz

Dear lsasim team,

In the following example, I can generate correlated ordinal background variables

N <- 100
d <- matrix(data = .4, nrow = 6, ncol = 6)
diag(d) <- 1

c_prop <- list(c(1),
               c(.2,.4,.6,.8,1),
               c(.1,.3,.5,.7,1),
               c(.3,.6,1),
               c(.7,.9,1),
               c(.4,.6,.9,1))

bgr_dt <- questionnaire_gen(n_obs = N, cat_prop = c_prop, cor_matrix = d, n_vars = 6, theta = TRUE) 

However, this function doesn't allow us to generate correlated multinomial variables, such as "race".

How can we achieve this?

Thank you,
Sinan

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions