| spatial_balance | R Documentation |
The Voronoi measure of Stevens and Olsen (2004): every unit of the frame is assigned to its nearest sampled unit, the inclusion probabilities assigned to each sampled unit are summed, and the balance is the mean squared deviation of those sums from one. Zero is perfect balance; simple random samples give values near one. With strata the measure is computed within each stratum and pooled.
spatial_balance(sample, by_stratum = FALSE)
sample |
A |
by_stratum |
Return one value per stratum instead of the pooled one. |
A number, or a named vector with by_stratum = TRUE.
Stevens, D. L. and Olsen, A. R. (2004). Spatially balanced sampling of natural resources. Journal of the American Statistical Association, 99, 262-278.
cells <- expand.grid(x = 1:10, y = 1:10)
spatial_balance(select_units(cells, n = 10, method = "lpm", seed = 1))
spatial_balance(select_units(cells, n = 10, method = "srs", seed = 1))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.