View source: R/make_sample_data.R
Makes a simple data frame with treat (binary), outcome (binary), and five covariates: X1 (continuous), X2 (continuous), B1 (binary), B2 (binary), and C1 (categorical). Probability outcome = 1 is sigmoid(treat + X1). Probability treatment = 1 is sigmoid(- 0.2 * X1 + X2 - B1 + 2 * B2)
make_sample_data(n = 100)
the size of the desired data set
# make sample data set of 30 observations dat <- make_sample_data(n = 30)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.