engine_sp_random | R Documentation |
sp
Uses sp::spsample()
with method "random" to produce points, converts back to sf
,
and spatial joins with input shp
.
Each engine function takes the same arguments and produces comparable outputs.
Final number of points may be approximate for this method.
engine_sp_random(shp, col)
shp |
input shp with |
col |
character column name to produce points with |
tibble with sf
geometries
set.seed(1) data('suffolk') engine_sp_random(suffolk[16:20,], 'pop_nhpi')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.