View source: R/sample_existing_strat.R
take_samples | R Documentation |
This function takes a data frame of existing data, a data frame of desired sample sizes for each strata, and a strata variable name, and returns a sample of the existing data based on the sample sizes for the specified strata.
take_samples(existing, toSample, strata)
existing |
A data frame containing existing data. |
toSample |
A data frame specifying the desired sample sizes for each strata. |
strata |
A string specifying the name of the variable used to define strata. |
A data frame containing a sample of the existing data based on the sample sizes for the specified strata.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.