swat.cas.table.CASColumn.sample

CASColumn.sample(n=None, frac=None, replace=False, weights=None, random_state=None, axis=None, stratify_by=None, **kwargs)

Returns a random sample of the CAS table rows

Parameters:
n : int, optional

The number of samples to return. The default is 1 if frac=None.

frac : float, optional

The percentage of rows to return.

replace : bool, optional

Not supported.

weights : str or ndarray-like, optional

Not supported.

random_state : int, optional

Seed for the random number generator.

axis : int or string, optional

Not supported.

stratify_by : string, optional

The variable to stratify by.

Returns:
CASTable