View source: R/generate_synthetic_data.R
generate_syn_data | R Documentation |
Generates synthetic data set based on different GPS models and covariates.
generate_syn_data( sample_size = 1000, outcome_sd = 10, gps_spec = 1, cova_spec = 1 )
sample_size |
Number of data samples. |
outcome_sd |
Standard deviation used to generate the outcome in the synthetic data set. |
gps_spec |
A numerical value (1-7) that indicates the GPS model used to generate synthetic data. See the code for more details. |
cova_spec |
A numerical value (1-2) to modify the covariates. See the code for more details. |
synthetic_data
: The function returns a data.frame saved the
constructed synthetic data.
set.seed(298) s_data <- generate_syn_data(sample_size=100, outcome_sd = 10, gps_spec = 1, cova_spec = 1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.