Documentation Center

  • Trial Software
  • Product Updates

random

Class: ProbDist

Generate random number drawn from ProbDist object

Syntax

Y = random(PD)
Y = random(PD, N)
Y = random(PD, N, M, ...)

Description

Y = random(PD) generates a random number drawn from the distribution specified by PD, a ProbDist object.

Y = random(PD, N) generates an N-by-N array of random numbers drawn from the distribution specified by PD, a ProbDist object.

Y = random(PD, N, M, ...) generates an N-by-M-by... array of random numbers drawn from the distribution specified by PD, a ProbDist object.

Input Arguments

PDAn object of the class ProbDistUnivParam or ProbDistUnivKernel.
NA positive integer.
MA positive integer.

Output Arguments

YA random number drawn from the distribution specified by PD.

See Also

Was this topic helpful?