R/forecast.R

Defines functions get_forecast

Documented in get_forecast

#' Get 3h forecast data.
#'
#' @inheritParams get_current
#'
#' @return list
#' @export
#'
#' @examples \dontrun{
#'    result <- get_forecast("Kassel", units = "metric")
#'    names(result)
#'    get_forecast("London", cnt = 10)
#'    get_forecast(lat = -22.90278, lon = -22.90278, cnt = 3, units = "metric")
#' }
get_forecast <- function(city = NA, ...) {
  get <- owmr_wrap_get("forecast")
  get(city, ...) %>%
    owmr_parse() %>%
    owmr_class("owmr_forecast")
}

Try the owmr package in your browser

Any scripts or data that you put into this service are public.

owmr documentation built on Jan. 11, 2020, 5:08 p.m.