pyprobound.table.sample_counts
- sample_counts(dataframe, n_counts=1000000, random_state=None)
Randomly samples n_counts total counts each column of a dataframe.
- Parameters:
dataframe (
DataFrame) – The dataframe to sample counts from.n_counts (
int) – The total number of counts to be included in the output.random_state (
int|None) – A seed used to make the output reproducible.
- Return type:
DataFrame- Returns:
A dataframe with approximately n_counts total counts.