is-distribution: Test if the object is a distribution

is_distributionR Documentation

Test if the object is a distribution

Description

[Stable]

This function returns TRUE for distributions and FALSE for all other objects.

Usage

is_distribution(x)

Arguments

x

An object.

Value

TRUE if the object inherits from the distribution class.

Examples

dist <- dist_normal()
is_distribution(dist)
is_distribution("distributional")

distributional documentation built on March 31, 2023, 7:12 p.m.