ll_match | R Documentation |
Matches a data frame with longitude and latitude to an sf object
ll_match(
data,
longitude = 1,
latitude = 2,
join = sf::st_intersects,
sample = NULL,
match = longlat2map::ll_get_world()
)
data |
A data frame or tibble with a column for longitude and one for latitude or an onject of the sf class. If an sf object is given, the longitude and latitude parameters are ignored. |
longitude |
The exact column name or the column index (e.g. 1 if first column) for longitude. Defaults to 1. |
latitude |
The exact column name or the column index (e.g. 1 if first column) for latitude. Defaults to 2. |
join |
A function of the sf class determining the type of join. Defaults to |
sample |
Defaults to NULL. If given, it runs the matching with only a subset of the original dataframe. Suggested for testing in particular when working with big datasets. |
match |
An sf object to be matched with the given dataframe, defaults to |
An sf object with CRS 4326.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.