Skip to content

crandas.random

randbytes(n, *, num_rows=1)

Generate secret random bytes.

PARAMETER DESCRIPTION
n

Length of the generated values in bytes.

TYPE: MaybePlaceholder[NonNegativeInt]

num_rows

Number of rows in the output, by default 1

TYPE: MaybePlaceholder[NonNegativeInt] DEFAULT: 1

RETURNS DESCRIPTION
CSeries

CSeries filled with secret random bytes.

randint(a, b, *, num_rows=1)

Generate secret random integer values in \([a, b]\), including both endpoints.

PARAMETER DESCRIPTION
a

Lower bound of the possible outputs, inclusive.

TYPE: MaybePlaceholder[int]

b

Upper bound of the possible outputs, inclusive.

TYPE: MaybePlaceholder[int]

num_rows

Number of rows in the output, by default 1

TYPE: MaybePlaceholder[NonNegativeInt] DEFAULT: 1

RETURNS DESCRIPTION
CSeries

CSeries filled with secret random integers.

random(*, num_rows=1, precision=20)

Generate secret random fixed-point values in \([0, 1)\).

PARAMETER DESCRIPTION
num_rows

Number of rows in the output.

TYPE: int DEFAULT: 1

precision

Precision of the generated fixed-point values.

TYPE: int DEFAULT: 20

RETURNS DESCRIPTION
CSeries

CSeries filled with secret random fixed-points.