pub fn gaussian<D, F>(arr: &mut Array<F, D>, indpb: f64, stdev: F)Available on crate feature
ndarray only.Expand description
Apply Gaussian noise to random elements.
This function does a random roll of probability indpb for each element in the input array.
If the roll succeeds, it adds noise to that element, drawn from a Gaussian/normal distribution
with mean 0 and standard deviation stdev.
ยงPanics
Panics if stdev is infinite, NaN, or negative.
Also panics if adding noise to an element would cause it to overflow or underflow, though this is pretty unlikely for most use cases.