timeatlas.time_series_dataset.TimeSeriesDataset.select_components_randomly

TimeSeriesDataset.select_components_randomly(n: int, seed: int = None, indices: bool = False) → Any

Returns a subset of the TimeSeriesDataset with randomly chosen n elements without replacement.

Parameters
  • n – number of elements returned

  • seed – seed for random generator

  • indices – if True returns the indices of the selection

Returns: TimeSeriesDataset (optional: indices of selection)