seq.mondate: Mondate Sequence Generation

View source: R/mondate.r

seq.mondateR Documentation

Mondate Sequence Generation

Description

Generate regular mondate sequences.

Usage

## S3 method for class 'mondate'
seq(from, to, ...)

Arguments

from

a mondate. May be "missing".

to

a mondate. May be "missing".

...

optional arguments passed to seq.default, including by, length.out, and along.with. See seq for more details.

Details

For more details about sequence generation, see seq.

If from and to are both provided, the displayFormat and timeunits properties are taken from from, without a warning if from's properties differ from to's.

Value

A mondate vector with displayFormat and timeunits from argument from, if provided, otherwise from argument to.

Author(s)

Dan Murphy

See Also

seq

Examples

x<-mondate.ymd(2010,1)
x                          # January 31, 2010
y<-mondate.ymd(2010,12)
y                          # December 31, 2010
seq(from=x, to=y)  # all month-ends in 2010
# 8 quarter-ends beginning 1st quarter 2009; US displayFormat
seq(mondate("3/31/2009"), by=3, length.out=8) 
# 8 quarter-ends ending year-end 2009; non-US displayFormat
seq(to=mondate("2009/12/31"), by=3, length.out=8) 

mondate documentation built on May 29, 2024, 1:32 a.m.

Related to seq.mondate in mondate...