get_wind_data: Obtain daily wind data for an IDenv with package nasapower...

View source: R/get_wind_data.R

get_wind_dataR Documentation

Obtain daily wind data for an IDenv with package nasapower derived by NASA from satellite & atmospheric observations.

Description

Function downloading daily weather data via the package nasapower based on longitude, latitude, planting and harvest date characterizing this environment.

Usage

get_wind_data(environment, info_environments, ...)

Arguments

environment

character Name of the environment for which climate data should be extracted.

info_environments

data.frame object with at least the 4 first columns.

  1. year: numeric Year label of the environment

  2. location: character Name of the location

  3. longitude: numeric longitude of the environment

  4. latitude: numeric latitude of the environment

  5. planting.date: (optional) Date YYYY-MM-DD

  6. harvest.date: (optional) Date YYYY-MM-DD

  7. IDenv: character ID of the environment (location x year)

The data.frame should contain as many rows as Year x Location combinations. Example: if only one location evaluated across four years, 4 rows should be present.

Value

a data.frame data.frame with the following columns extracted from POWER data, according to requested parameters:

  1. longitude numeric

  2. latitude numeric

  3. YEAR numeric

  4. MM integer

  5. DD integer

  6. DOY integer

  7. YYYYMMDD Date

  8. WS2M numeric

  9. IDenv character ID environment for which weather data were downloaded.

  10. length.gs difftime length in days of the growing season for the environment.

Author(s)

Cathy C. Westhues cathy.jubin@hotmail.com

References

\insertRef

sparks2018nasapowerlearnMET


cjubin/learnMET documentation built on Nov. 4, 2024, 6:23 p.m.