Description Usage Arguments Value Caution dplyr Compatibility Note Author(s) See Also Examples
Retrieves daily observations for a given station.
1 2 3 4 5 6 7 8 9 10 11 12 13 |
stationid |
BOM station ‘ID’. See Details. |
latlon |
Length-2 numeric vector of Latitude/Longitude. See Details. |
radius |
Numeric value, distance (km) from latlon, must be numeric. |
type |
Measurement type for |
A bomrang_tbl
object (extension of a
data.frame
) of historical observations for the selected
station/product type, with some subset of the following columns:
product_code: | BOM internal code. |
station_number: | BOM station ID. |
year: | Year of observation (YYYY). |
month: | Month of observation (1-12). |
day: | Day of observation (1-31). |
min_temperature: | Minimum daily recorded temperature (degrees C). |
max_temperature: | Maximum daily recorded temperature (degrees C). |
accum_days_min: | Accumulated number of days of minimum temperature. |
accum_days_max: | Accumulated number of days of maximum temperature. |
rainfall: | Daily recorded rainfall in mm. |
period: | Period over which rainfall was measured. |
solar_exposure: | Daily global solar exposure in MJ/m^2. |
quality: | Y, N, or missing. Data which have not yet completed the |
routine quality control process are marked accordingly. |
The following attributes are set on the data, and these are used to generate the header:
site: | BOM station ID. |
name: | BOM station name. |
lat: | Latitude in decimal degrees. |
lon: | Longitude in decimal degrees. |
start: | Date observations start. |
end: | Date observations end. |
years: | Available number of years data. |
percent: | Percent complete. |
AWS: | Automated weather station? |
type: | Measurement types available for the station. |
Temperature data prior to 1910 should be used with extreme caution as many stations prior to that date were exposed in non-standard shelters. Some of which give readings which are several degrees warmer or cooler than those measured according to post-1910 standards.
Daily maximum temperatures usually occur in the afternoon and daily minimum temperatures overnight or near dawn. Occasionally, however, the lowest temperature in the 24 hours to prior to 9 AM can occur around 9 AM the previous day if the night was particularly warm.
Either stationid
or latlon
must be provided, but if both are,
then stationid
will be used as it is more reliable.
In some cases data is available back to the 1800s, so tens-of-thousands of daily records will be returned. Other stations will be newer and will return fewer observations.
The bomrang_tbl
class is
compatible with dplyr
as long as the
bomrang
package is on the search path. Common functions
(filter
, select
,
arrange
, mutate
,
rename
, arrange
,
slice
, group_by
) are provided
which mask the dplyr versions (but use those internally,
maintaining attributes).
Methods get_historical_weather
and get_historical
are
equivalent. No preference is given to the use of either.
Jonathan Carroll, rpkg@jcarroll.com.au
get_current_weather
1 2 3 4 5 6 7 8 9 10 | get_historical_weather(stationid = "023000",
type = "max") ## ~48,000+ daily records
get_historical_weather(latlon = c(-35.2809, 149.1300),
type = "min") ## 3,500+ daily records
get_historical(stationid = "023000",
type = "max") ## ~48,000+ daily records
get_historical(latlon = c(-35.2809, 149.1300),
type = "min") ## 3,500+ daily records
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.