seed()
- Initialize the random number generator
getstate()
- Returns the current internal state of the random number generator
setstate()
- Restores the internal state of the random number generator
getrandbits()
- Returns a number representing the random bits
randrange()
- Returns a random number between the given range
randint()
- Returns a random number between the given numbers
choice()
- Returns a random element from the given sequence
choices()
- Returns a list with a random selection from the given sequence
shuffle()
- Takes a sequence and returns the sequence in a random order
sample()
- Returns a given sample of a sequence
random()
- Returns a random float number between 0 and 1
uniform()
- Returns a random float number between two given parameters
triangular()
- Returns a random float number between two given parameters, you can also set a mode parameter to specify the midpoint between the two other parameters
Statistics
betavariate()
- Returns a random float number between 0 and 1 based on the Beta distribution
expovariate()
- Returns a random float number based on the Exponential distribution
gammavariate()
- Returns a random float number based on the Gamma distribution
weibullvariate()
- Returns a random float number based on the Weibull distribution
Probability
gauss()
- Returns a random float number based on the Gaussian distribution
lognormvariate()
- Returns a random float number based on a log-normal distribution
normalvariate()
- Returns a random float number based on the normal distribution
paretovariate()
- Returns a random float number based on the Pareto distribution
Directional Statistics
vonmisesvariate()
- Returns a random float number based on the von Mises distribution
ย