The DiscountFactor class is designed to represent discount factors. Checks
whether: d1 is less than d2, elementwise, and that both are Date
vectors; and value is greater than zero and is a numeric vector. An error
is thrown if any of these are not true. The elements of each argument are
recycled such that each resulting vectors have equivalent lengths.
Usage
DiscountFactor(value, d1, d2)
Arguments
value
a numeric vector containing discount factor values. Must be
greater than zero
d1
a Date vector containing the as of date
d2
a Date vector containing the date to which the discount factor
applies