dynamic_proj_dates function

Generate vector of dates for dynamic projections

Generate vector of dates for dynamic projections

Creates a vector of dates at regular intervals between two given dates.

dynamic_proj_dates(startdate, enddate, interval.level, interval)

Arguments

  • startdate: a character string, the start date in format "YYYY-MM-DD".

  • enddate: a character string, the end date in format "YYYY-MM-DD".

  • interval.level: a character string, the time-step of intervals. One of day,week, month

    or year: can be abbreviated.

  • interval: a numeric value, the length of interval in interval.level units to generate between the start and end date.

Returns

Vector of dates between start date and end date split at regular intervals.

Details

Function returns a vector of dates between start.date and end.date at given interval size.

Examples

dynamic_proj_dates( startdate = "2000-01-01", enddate = "2001-01-01", interval.level = "month", interval = 2 )
  • Maintainer: Rachel Dobson
  • License: GPL (>= 3)
  • Last published: 2024-06-28