Days in Period
dip.Rd
Given any starting and ending dates, it generates:
1) a vector of class Date with all the days between from
and to
(both of them included), OR
2) the amount of days between the two dates
Arguments
- from
Character indicating the starting date for creating the sequence. It has to be in the format indicated by
date.fmt
.- to
Character indicating the ending date for creating the sequence. It has to be in the format indicated by
date.fmt
.- date.fmt
character indicating the format in which the dates are stored in
from
andto
, e.g. %Y-%m-%d. Seeformat
inas.Date
.
ONLY required whenclass(dates)=="factor"
orclass(dates)=="numeric"
.- out.type
Character indicating the type of result that is given by this function. Valid values are:
1) seq : a vector of class Date with all the days between the two dates, OR
2) nmbr: a single numeric value with the amount of days between the two dates.
Value
Depending on the value of out.type
, it returns:
1) a vector of class Date with all the days between from
and to
(both of them included), OR
2) the amount of days between the two dates
Author
Mauricio Zambrano-Bigiarini, mzb.devel@gmail