Statistics Toolbox
  Go to function:
    Search    Help Desk 
unidcdf    Examples

Discrete uniform cumulative distribution (cdf) function.

Syntax

Description

unidcdf(X,N) computes the discrete uniform cdf 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 maximum observable value, N, is a positive integer.

The discrete uniform cdf is:


The result, p, is the probability that a single observation from the discrete uniform distribution with maximum, N, will be a positive integer less than or equal to x. The values, x, do not need to be integers.

Examples

What is the probability of drawing a number 20 or less from a hat with the numbers from 1 to 50 inside?



[ Previous | Help Desk | Next ]