date_to_JDay: Transform dates into JDay

View source: R/date_to_JDay.R

date_to_JDayR Documentation

Transform dates into JDay

Description

In agricultural assessments, the begining and end for a period of interest (e.g. chill accumulation) are often expressed as Julian days (JDay) or Day Of the Year (DOY). This function transform dates into JDays without the need of looking at external resources for the information

Usage

date_to_JDay(date, format)

Arguments

date

Character string or date class elements. This is the date for which the function must return the JDay. The function also accepts a vector of length > 1

format

Character string. This is the format in which the date(s) are introduced when calling the function. See base::as.Date

Examples


date_to_JDay(date = c("15/10/2020", "15/10/2019", "01/08/2003"), 
             format = "%d/%m/%Y")


EduardoFernandezC/dormancyR documentation built on Aug. 24, 2022, 7:21 a.m.