Make map markers from a simple feature object
Usage
make_markers(
data,
groupname_col = NULL,
group_meta = NULL,
join = sf::st_intersects,
geocode = FALSE,
address_col = "address",
point = TRUE,
crs = NULL,
fn = NULL,
...
)
Arguments
- data
Data with markers, passed to data parameter of
get_location_data()
- groupname_col
Group column name, used to join group metadata if group_meta is a non-spatial data frame; Default:
NULL
- group_meta
Group metadata as a data frame or sf object that intersect with markers; Default:
NULL
- join
The join function used by
sf::st_join()
if group_meta is an sf object, Default: sf::st_intersects- geocode
If
TRUE
, geocode data using tidygeocoder::geo and then convert to sf with df_to_sf, Default:FALSE
- address_col
Address column, used if geocode is
TRUE
Default: 'address'- point
If
TRUE
, convert geometry to "POINT" withsf::st_centroid()
, Default:TRUE
- crs
Coordinate reference system for markers, Default:
NULL
- fn
Function to apply to data before results; gives warning if data is grouped; Default:
NULL
- ...
Additional parameters passed to
get_location_data()