View source: R/EEAaq_map_stations.R
EEAaq_map_stations | R Documentation |
EEAaq_df
or EEAaq_df_sfc
.Create a static or dynamic (interactive leaflet) map representing the geographical locations of the
stations based on a user-defined input dataset of class EEAaq_df
or EEAaq_df_sfc
.
EEAaq_map_stations(
data = NULL,
NUTS_extborder = NULL,
NUTS_intborder = NULL,
color = TRUE,
dynamic = FALSE
)
data |
an |
NUTS_extborder |
character containing the NUTS level or LAU for which draw external boundaries. Admissible values are 'NUTS0', 'NUTS1', 'NUTS2', 'NUTS3', 'LAU'. Recall that the NUTS classification (Nomenclature of territorial units for statistics) is a hierarchical system for dividing up the economic territory of the EU and the UK. The levels are defined as follows:
|
NUTS_intborder |
character containing the NUTS level or LAU for which draw internal boundaries. Admissible values are 'NUTS0', 'NUTS1', 'NUTS2', 'NUTS3', 'LAU'. |
color |
logical value (T or F). If |
dynamic |
logical value (T or F). If |
A map representing the specified area and the points representing the location of the stations able to detect the specified pollutants.
library(sf)
`%>%` <- dplyr::`%>%`
### Retrieve all the stations measuring PM10 in Belgium
IDstations <- EEAaq_get_stations(byStation = FALSE, complete = TRUE)
IDstations <- IDstations %>%
dplyr::filter(ISO %in% c("BE"),
is.na(OperationalActivityEnd),
AirPollutant %in% "PM10") %>%
dplyr::pull(AirQualityStationEoICode) %>%
unique()
### Download the corresponding data from December 1st to December 31st, 2021
data <- EEAaq_get_data(IDstations = IDstations, pollutants = "PM10",
from = "2021-12-01", to = "2021-12-31",
verbose = TRUE)
### Static map of available stations across the whole country.
### External borders are given by the union of the available regions (NUTS-2),
### while municipalities (LAUs) are used as inner borders.
EEAaq_map_stations(data = data,
NUTS_extborder = "NUTS1", NUTS_intborder = "NUTS2",
color = TRUE, dynamic = FALSE)
### Dynamic (interactive leaflet) map of available stations across the whole
### country. External borders are given by the union of the available
### regions (NUTS-2), while provinces (NUTS-3) are used as inner borders.
EEAaq_map_stations(data = data,
NUTS_extborder = "NUTS2", NUTS_intborder = "NUTS3",
color = TRUE, dynamic = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.