The returned value should have the following operations:

  • min: a vector, the minimum value of the support for each component.

  • max: a vector, the maximum value of the support for each component.

  • call: a predicate function, which returns TRUE if the value is in the support, and FALSE otherwise.

  • sample: a function, which returns a sample from the support. Note that the returned value is not guaranteed to be in the support of x. You may need to call call to check.

sup(x)

Arguments

x

The object to obtain the support of.

Value

A support object for x.

Examples

x <- normal(0, 1)
S <- sup(x)
infimum(S)   # -Inf
#> [1] -Inf
supremum(S)  # Inf
#> [1] Inf

y <- exponential(1)
S2 <- sup(y)
infimum(S2)  # 0
#> [1] 0