bundles / scipy latest / scipy / stats / _distribution_infrastructure / _Parameter / draw
function
scipy.stats._distribution_infrastructure:_Parameter.draw
Signature
def draw ( self , size = None , * , rng = None , region = domain , proportions = None , parameter_values = None ) Summary
Draw random values of the parameter for use in testing.
Parameters
size: tuple of intsThe shape of the array of valid values to be drawn.
rng: np.GeneratorThe Generator used for drawing random values.
region: strThe region of the _Parameter from which to draw. Default is "domain" (the full domain); alternative is "typical". An enhancement would give a way to interpolate between the two.
proportions: tuple of numbersA tuple of four non-negative numbers that indicate the expected relative proportion of elements that:
are strictly within the domain,
are at one of the two endpoints,
are strictly outside the domain, and
are NaN,
respectively. Default is (1, 0, 0, 0). The number of elements in each category is drawn from the multinomial distribution with
np.prod(size)as the number of trials andproportionsas the event probabilities. The values inproportionsare automatically normalized to sum to 1.parameter_values: dictMap between the names of parameters (that define the endpoints of
typical) and numerical values (arrays).
Aliases
-
scipy.stats._distribution_infrastructure._Parameter.draw