Weather change Iowa Mesonet

Usage

weach_imn(data, lati, ts = 1, temp.units = c("Fahrenheit", "Celsius"), rh.units = c("percent", "fraction"), ws.units = c("mph", "mps"), pp.units = c("in", "mm"), ...)

Arguments

data
data as obtained from the Iowa Mesonet (see details)
lati
Latitude, not used at the moment
ts
Time step, not used at the moment
temp.units
Temperature units
rh.units
Relative humidity units
ws.units
wind speed units
pp.units
precipitation units
...

Value

It will return a data frame in the same format as the weach function.

Description

Manipulates weather data in the format obtained from Iowa Mesonet (see link below) and returns the format and units needed for most functions in this package. This function should be used for one year at a time. It takes and returns hourly weather information only.

Details

This function should be used to transform data from the Iowa Mesonet at hourly intervals from here:

http://mesonet.agron.iastate.edu/agclimate/hist/hourlyRequest.php

When selecting to download variables: Air Temperature (Fahrenheit) Solar Radiation (kilocalories per meter squared) Precipitation (inches) Relative humidity (percent) Wind Speed (mph)

You can read the data directly as it is downloaded making sure you skip the first 6 lines (This includes the title row).

The imported data frame should have 9 columns with:

  1. site ID
  2. site name
  3. date in format "year-month-day", e.g. '2010-3-25'
  4. hour in format "hour:minute", e.g. '15:00'
  5. temperature (Fahrenheit)
  6. solar radiation (kilocalories per meter squared)
  7. precipitation (inches)
  8. relative humidity (%).
  9. wind speed (mph)

above~~

Note

References

Iowa Mesonet http://mesonet.agron.iastate.edu/index.phtml

Examples

## Read an example data set from my website url <- "http://www.agron.iastate.edu/miguezlab/teaching/CropSoilModel/ames_2010-iowamesonet.txt" ames.wea <- read.table(url, skip = 6) ames.wea2 <- weach_imn(ames.wea)

See also

weach help, ~~~

Author

Fernando E. Miguez