npn_get_custom_agdd_time_series: Get Custom AGDD Time Series

View source: R/npn_geoserver.R

npn_get_custom_agdd_time_seriesR Documentation

Get Custom AGDD Time Series

Description

This function takes a series of variables used in calculating AGDD and returns an AGDD time series, based on start and end date, for a given location in the continental US. This function leverages the USA-NPN geo web services

Usage

npn_get_custom_agdd_time_series(
  method,
  start_date,
  end_date,
  base_temp,
  climate_data_source,
  temp_unit,
  lat,
  long,
  upper_threshold = NULL
)

Arguments

method

Takes "simple" or "double-sine" as input. This is the AGDD calculation method to use for each data point. Simple refers to simple averaging.

start_date

Date at which to begin the AGDD calculations

end_date

Date at which to end the AGDD calculations

base_temp

This is the lowest temperature for each day for it to be considered in the calculation.

climate_data_source

Specified the climate data set to use. Takes either "PRISM" or "NCEP" as input.

temp_unit

The unit of temperature to use in the calculation. Takes either "Fahrenheit" or "Celsius" as input.

lat

The latitude of the location for which to calculate the time series

long

The longitude of the location for which to calculate the time series

upper_threshold

This parameter is only applicable for the double-sine method. This sets the highest temperature to be considered in any given day's AGDD calculation

Value

A data frame containing the numeric AGDD values for each day for the specified time period/location/method/base temp/data source.


usa-npn/rnpn documentation built on Feb. 4, 2024, 7:29 a.m.