View source: R/get_historical_weather.R
get_historical_weather | R Documentation |
Download point-level historical weather (ERA5) using open-meteo API
get_historical_weather(
latitude,
longitude,
site_id = NULL,
start_date,
end_date,
variables = c("relative_humidity_2m", "precipitation", "wind_speed_10m", "cloud_cover",
"temperature_2m", "shortwave_radiation")
)
latitude |
latitude degree north |
longitude |
longitude degree east |
site_id |
name of site location (optional, default = NULL) |
start_date |
earliest date requested. Must be on or after 1950-01-01 |
end_date |
latest date requested |
variables |
vector of name of variable(s) https://open-meteo.com/en/docs/ensemble-api |
data frame with the results from the call to the open-meteo API. The data frame is in a long format and has the following columns: "datetime", "site_id", "model_id", "variable", "prediction","unit".
get_historical_weather(
latitude = 37.30,
longitude = -79.83,
start_date = "2023-01-01",
end_date = Sys.Date(),
variables = c("temperature_2m"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.