Learn R Programming

openair (version 1.0)

airbaseFindCode: Helper function to find EEA airbase site codes

Description

Helper function to find airbase site codes

Usage

airbaseFindCode(country = c("AL", "AT", "BA", "BE", "BG", "CH", "CY", "CZ",
  "DE", "DK", "EE", "ES", "FI", "FR", "GB", "GR", "HR", "HU", "IE", "IS", "IT",
  "LI", "LT", "LU", "LV", "ME", "MK", "MT", "NL", "NO", "PL", "PT", "RO", "RS",
  "SE", "SI", "SK", "TR"), site.type = c("background", "traffic",
  "industrial", "unknown"), area.type = c("rural", "urban", "suburban",
  "unknown"), local.code = NA, city = NA, site = NA, emep = NA,
  lat = c(-90, 90), lon = c(-180, 180))

Arguments

country
A character or vector of characters representing country code.
site.type
One of background, traffic, industrial, unknown representing the type of site.
area.type
The type of area in which the site is located. Can be rural, urban, suburban, unknown.
local.code
A character or vector of characters representing the local site code. For example MY1 is the UK code for Marylebone Road.
city
A city name to search --- using character matching (grep). The search string can be upper or lower case e.g. city = "london". To extract several cities e.g. Copenhagen and Barcelona use city = c("copenhagen", "barcelona")
site
The name of the site or sites to search, see city for details of how to search.
emep
Select an EMEP station. Can be yes, no or NA (the default, selects everything).
lat
The latitude range to select in the form c(lower, upper).
lon
The longitude range to select in the form c(lower, upper).

Value

  • A vector of airbase site codes that can be used directly in importAirbase.

Details

This function helps to identify airbase site codes based on one or more criteria. The criteria include country code, site type, local site code, city, site name and latitude/longitude ranges.

See Also

importAirbase, airbaseFindCode, airbaseStats and airbaseInfo

Examples

Run this code
## select all sites in Denmark
sites <- airbaseFindCode(country = "DK")

## traffic sites in Germany and the UK
sites <- airbaseFindCode(country = c("DE", "GB"), site.type = "traffic")

Run the code above in your browser using DataLab