lognormal_distribution#
Defines Lognormal Distribution.
- class LogNormalDistribution(mu: Union[float, int], sigma: Union[float, int])#
Bases:
objectAn object which samples values from a log-normal distributions.
- mu#
Mean (“centre”) of the distributions.
- sigma#
Standard deviation (spread or “width”) of the distributions.
- Must be non-negative.
- Raises:
ValueError – If sigma < 0.
TypeError – If mu is not float or int.
TypeError – If sigma is not float or int.
Inits LogNormalDistribution with the provided arguments.
- Parameters:
mu – Mean (“centre”) of the distributions.
sigma – Standard deviation (spread or “width”) of the distributions. Must be non-negative.
- get_random_values(n: int) list[float]#
Samples an array with the given distribution.
- Parameters:
n – The number of values.
- Returns:
np.ndarray[float]
- get_samples_from_hypercube(n: int) list[float]#
Samples n values from a hypercube.
- Parameters:
n – the number of samples.
- Returns:
Samples of the distribution, sampled from a hypercube.