sf_to_spm | R Documentation |
sf
to spm
Transforming a sf
into a spm
object (Internal use)
single_sf_to_spm(
sf_obj,
n_pts,
type = "regular",
by_polygon = FALSE,
poly_ids = NULL,
var_ids = NULL,
trunc_d = NULL
)
sf_to_spm(
sf_obj,
n_pts,
type = "regular",
by_polygon = FALSE,
poly_ids = NULL,
var_ids = NULL,
trunc_d = NULL
)
sf_obj |
a |
n_pts |
a |
type |
a |
by_polygon |
a |
poly_ids |
a |
var_ids |
a scalar or vector of type |
trunc_d |
truncation distance for grid points. Consider using half of the maximum distance between polygons |
a named list
of size 6 belonging to the class
spm
. This list stores all the objects necessary to fit models
using the fit_spm
.
data(liv_lsoa) # loading the LSOA data
msoa_spm <- sf_to_spm(sf_obj = liv_msoa, n_pts = 1000,
type = "regular", by_polygon = FALSE,
poly_ids = "msoa11cd",
var_ids = "leb_est")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.