Skip to main content

latin_hypercube

Function latin_hypercube 

Source
pub fn latin_hypercube<R: Rng + ?Sized>(
    n: usize,
    d: usize,
    rng: &mut R,
) -> DMatrix<f64>
Expand description

Generate Latin hypercube samples.

Latin hypercube sampling is a stratified sampling method that ensures better coverage of the parameter space than pure random sampling.

§Arguments

  • n - Number of samples
  • d - Dimension
  • rng - Random number generator

§Returns

Matrix of shape (n, d) with samples in [0, 1]^d