optim_sample_strata {resemble} | R Documentation |
for internal use only! This function computes the optimal strata from the distribution of the given y
optim_sample_strata(y, n)
y |
a matrix of one column with the response variable. |
n |
number of samples that must be sampled. |
a list with two data.table
objects: sample_strata
contains
the optimal strata, whereas samples_to_get
contains information on how
many samples per stratum are supposed to be drawn.