gemseo / uncertainty / distributions / scipy

Hide inherited members

joint module

The SciPy-based joint probability distribution.

SPJointDistribution is a BaseJointDistribution based on the SciPy library.

Warning

For the moment, there is no copula that can be used with SPJointDistribution; if you want to introduce dependency between random variables, please consider OTJointDistribution.

class gemseo.uncertainty.distributions.scipy.joint.SPJointDistribution(distributions, copula=None)[source]

Bases: BaseJointDistribution

The SciPy-based joint probability distribution.

Initialize self. See help(type(self)) for accurate signature.

Parameters:
  • distributions (Sequence[SPDistribution]) – The marginal distributions.

  • copula (None) – A copula distribution defining the dependency structure between random variables; if None, consider an independent copula.

Raises:

NotImplementedError – When the copula is not None.

compute_cdf(vector)[source]

Evaluate the cumulative density function (CDF).

Parameters:

vector (Iterable[float]) – The description is missing.

Returns:

The value of the CDF.

Return type:

RealArray

compute_inverse_cdf(vector)[source]

Evaluate the inverse cumulative density function (ICDF).

Parameters:

vector (Iterable[float]) – The description is missing.

Returns:

The value of the ICDF.

Return type:

RealArray

compute_samples(n_samples=1)

Sample the random variable.

Parameters:

n_samples (int) –

The number of samples.

By default it is set to 1.

Returns:

The samples of the random variable.

Return type:

ndarray[Any, dtype[floating[Any]]]

DEFAULT_VARIABLE_NAME: Final[str] = 'x'

The default name of the variable.

property dimension: int

The dimension of the uncertain space.

distribution: _DistributionT

The probability distribution of the random variable.

property marginals: Sequence[BaseDistribution]

The marginal distributions.

math_lower_bound: _VariableT

The mathematical lower bound of the random variable.

math_upper_bound: _VariableT

The mathematical upper bound of the random variable.

property mean: ndarray[Any, dtype[floating[Any]]]

The expectation of the random variable.

num_lower_bound: _VariableT

The numerical lower bound of the random variable.

num_upper_bound: _VariableT

The numerical upper bound of the random variable.

property range: ndarray[Any, dtype[floating[Any]]]

The numerical range.

The numerical range is the interval defined by the lower and upper bounds numerically reachable by the random variable.

property standard_deviation: ndarray[Any, dtype[floating[Any]]]

The standard deviation of the random variable.

property support: ndarray[Any, dtype[floating[Any]]]

The mathematical support.

The mathematical support is the interval defined by the theoretical lower and upper bounds of the random variable.

transformation: str

The transformation applied to the random variable noted "x".

E.g. "sin(x)".