
Last chance! 50% off unlimited learning
Sale ends in
ExtendTime(dates, number.of.periods, dt = NULL)
Date
.dates
. Possible values are "daily", "weekly", "monthly",
"quarterly", "yearly", or "other". An attempt to deduce dt
will be made if it is missing.number.of.periods
is longer than length(dates)
, then
dates
will be padded to the desired length. Extra dates are
added at time intervals matching the average interval in
dates
. Thus they may not bebsts.mixed
.origin.month <- as.Date("2011-09-01")
week.ending <- as.Date(c("2011-10-01", ## 1
"2011-10-08", ## 2
"2011-12-03", ## 3
"2011-12-31")) ## 4
MatchWeekToMonth(week.ending, origin.month) == 1:4
Run the code above in your browser using DataLab