Statistics Toolbox
  Go to function:
    Search    Help Desk 
unidpdf    Examples

Discrete uniform probability density function (pdf).

Syntax

Description

unidpdf(X,N) computes the discrete uniform pdf with parameter settings, N, at the values in X. The arguments X and N must be the same size except that a scalar argument functions as a constant matrix of the same size of the other argument.

The parameter N must be a positive integer.

The discrete uniform pdf is:


You can think of y as the probability of observing any one number between 1 and n.

Examples

For fixed n, the uniform discrete pdf is a constant.

Now fix x , and vary n.



[ Previous | Help Desk | Next ]