Learn R Programming

dint (version 2.1.4)

Ops.date_xx: Comparison Operators for date_xx

Description

Comparison Operators for date_xx

Usage

# S3 method for date_xx
Ops(e1, e2)

Value

a logical scalar

Arguments

e1, e2

Objects with the same date_xx subclass (one of them can also be integer)

Examples

Run this code
date_yq(2015, 1) < date_yq(2015, 2)

# comparison with integers is ok
date_yq(2015, 1) < 20152

# but two different date_xx cannot be compared
try(date_yq(2015, 1) < date_ym(2015, 2))

Run the code above in your browser using DataLab