DataDiscrete.sample_around

DataDiscrete.sample_around(centroid: ndarray, n_samples: int, percentage: int, **kwargs) ndarray[source]

Returns samples from the domain of the data object around the given centroid.

Parameters:
  • centroid (np.ndarray) – Centroid around which to sample.

  • n_samples (int) – Number of samples to return.

  • percentage (int) – Controls the range of the samples. If 100, the samples are drawn from the whole domain. If 50, the samples are drawn from the half of the domain around the centroid.