| simulate_mnl_data | R Documentation |
Generates synthetic choice data with i.i.d. Gumbel errors, optionally with varying choice-set sizes and an outside option (alt = 0). Choices are determined by argmax of utility; covariates are drawn as Uniform(-1, 1).
simulate_mnl_data(
N = 5000,
J = 5,
beta = c(0.8, -0.6),
delta = NULL,
seed = 123,
outside_option = TRUE,
vary_choice_set = TRUE
)
N |
Number of choice situations. |
J |
Number of inside alternatives. |
beta |
Fixed coefficients for |
delta |
Alternative-specific constants for inside alternatives
(length |
seed |
Random seed. Pass |
outside_option |
Logical; if |
vary_choice_set |
Logical; if |
A choicer_sim object.
sim <- simulate_mnl_data(N = 1000, J = 5, seed = 123)
print(sim)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.