bundles / scipy latest / scipy / stats / _kde / gaussian_kde / resample
function
scipy.stats._kde:gaussian_kde.resample
source: /scipy/stats/_kde.py :456
Signature
def resample ( self , size = None , seed = None ) Summary
Randomly sample a dataset from the estimated pdf.
Parameters
size: int, optionalThe number of samples to draw. If not provided, then the size is the same as the effective number of samples in the underlying dataset.
seed: {None, int, `numpy.random.Generator`, `numpy.random.RandomState`}, optionalIf
seedis None (ornp.random), the numpy.random.RandomState singleton is used. Ifseedis an int, a newRandomStateinstance is used, seeded withseed. Ifseedis already aGeneratororRandomStateinstance then that instance is used.
Returns
resample: (self.d, `size`) ndarrayThe sampled dataset.
Aliases
-
scipy.stats.gaussian_kde.resample