Learn R Programming

tolBasis (version 1.0)

Dseq: Date Sequence

Description

Date sequence in a Dating

Usage

Dseq(from, to, dating, len) # Sequence of dates in an interval # Dseq(from, to, dating, ) # Sequence of dates from a date # Dseq(from, , dating, lenght.out)

Arguments

from
the Date o POSIXt objet indicating the minimum date
to
the Date o POSIXt objet indicating the maximum date
dating
a Dating object
len
the number of obtained dates whether the argument to is missing

Value

Returns a vector of dates belonging to the dating in the interval [from, to] If the argument to is missing returns a vector with the length 'len'.

Examples

Run this code
# Vector of the monthly dates of the current year
currYear <- Dfloor(Sys.Date(), Yearly)
Dseq(currYear, dating=Monthly, len=12)

Run the code above in your browser using DataLab