Learn R Programming

distr6 (version 1.0.0)

Interval: R6 Generalised Class for Symbolic Intervals

Description

A symbolic R6 Interval class.

Value

Returns an R6 object of class Interval.

Constructor

Interval$new(lower = -Inf, upper = Inf, type = "[]", class = "numeric", dim = 1)

Constructor Arguments

Argument Type Details
lower numeric Lower limit of interval.
upper numeric Upper limit of interval.
type character Interval type, one of (), (], [), [].
class character Atomic class, one of "numeric" or "integer".

Public Methods

Accessor Methods Link
type() type.SetInterval
dimension() dimension.SetInterval
max() max.SetInterval
min() min.SetInterval
sup() sup.SetInterval
inf() inf.SetInterval
getSymbol() getSymbol.SetInterval
class() class.SetInterval
Interval Methods Link
length() length.Interval
as.numeric() as.numeric.Interval
Validation Methods Link
liesInSetInterval(x, all = FALSE, bound = FALSE) liesInSetInterval
Representation Methods Link
print() print

Details

Intervals are distinguished from sets in R6 as they can take an infinite range and are defined over a continuous range (albeit integer or numeric).

See Also

Set