Title: | R Interface to OpenWeatherMap API |
---|---|
Description: | OpenWeatherMap (OWM) <http://openweathermap.org/api> is a service providing weather related data. This package can be used to access current weather data for one location or several locations. It can also be used to forecast weather for 5 days with data for every 3 hours. |
Authors: | Mukul Chaware[aut,cre] |
Maintainer: | Mukul Chaware <[email protected]> |
License: | MIT + file LICENSE |
Version: | 1.1 |
Built: | 2024-11-04 03:32:56 UTC |
Source: | https://github.com/mukul13/ropenweathermap |
get current weather data for one location
get_current_weather(api_key, cityID = NA, city = "", country = "", coordinates = NA, zip_code = NA)
get_current_weather(api_key, cityID = NA, city = "", country = "", coordinates = NA, zip_code = NA)
api_key |
Open weather map API key |
cityID |
city ID |
city |
name of city |
country |
name of country |
coordinates |
(lat,lon) coordinates of the location of your interest |
zip_code |
zip code |
data frame giving current weather data for one location
## Not run: data=get_current_weather(api_key,city="guwahati") ## End(Not run)
## Not run: data=get_current_weather(api_key,city="guwahati") ## End(Not run)
get current weather data for multiple cities
get_multiple_cities(api_key, bbox = NA, coordinates = NA, count = NA, cityIDs = NA, cluster = "yes", units = "metric")
get_multiple_cities(api_key, bbox = NA, coordinates = NA, count = NA, cityIDs = NA, cluster = "yes", units = "metric")
api_key |
Open weather map API key |
bbox |
bounding box [lat of the top left point, lon of the top left point, lat of the bottom right point, lon of the bottom right point, map zoom] |
coordinates |
(lat,lon) coordinates of the location of your interest |
count |
number of cities around the point that should be returned |
cityIDs |
city IDs |
cluster |
use server clustering of points. Possible values are [yes, no] |
units |
metric units |
data frame giving current weather data for several locations
## Not run: data=get_multiple_cities(api_key,cityIDs =c(524901,703448,2643743)) ## End(Not run)
## Not run: data=get_multiple_cities(api_key,cityIDs =c(524901,703448,2643743)) ## End(Not run)
get weather forecast data for one location
get_weather_forecast(api_key, cityID = NA, city = "", country = "", coordinates = NA)
get_weather_forecast(api_key, cityID = NA, city = "", country = "", coordinates = NA)
api_key |
Open weather map API key |
cityID |
city ID |
city |
name of city |
country |
name of country |
coordinates |
(lat,lon) coordinates of the location of your interest |
data frame giving weather forecast data for one location
## Not run: data=get_weather_forecast(api_key,city="guwahati") ## End(Not run)
## Not run: data=get_weather_forecast(api_key,city="guwahati") ## End(Not run)