View source: R/sup_generate_data.R
sup_generate_data | R Documentation |
Draw distribution-specific parameters theta_1, ..., theta_k ~ N(mu, tau^2). For each distribution j, draw covariates X_j1, ..., X_jn_j ~ N(0, 1), and draw outcomes Y_ji = theta_j*X_ji + epsilon_ji, epsilon_ji ~ N(0, sigma^2).
sup_generate_data(k, n, mu, tau_sq, sigma_sq)
k |
Number of subjects |
n |
Number of observations from each subject. For our examples, we assume this is equal across subjects. |
mu |
Mean of parameter distribution |
tau_sq |
Variance of parameter distribution |
sigma_sq |
Variance of epsilon in response model |
A list of length k, where each item contains a data frame of observations from a single distribution
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.