PERM Function


Computes the number of permutations of n items taken r at a time

Category: Mathematical

Syntax

PERM ( n <, r >)

Arguments

n

  • is an integer that represents the total number of elements from which the sample is chosen .

r

  • is an optional integer value that represents the number of chosen elements. If r is omitted, the function returns the factorial of n .

  • Restriction: r n

Details

The mathematical representation of the PERM function is given by the following equation:

click to expand

with n 0, r 0, and n r .

If the expression cannot be computed, a missing value is returned.

Examples

SAS Statements

Results

x=perm(5,1);

5

x=perm(5);

120

x=perm(5,2)

20

See Also

Functions:

  • 'COMB Function' on page 444

  • 'FACT Function' on page 517




SAS 9.1 Language Reference Dictionary, Volumes 1, 2 and 3
SAS 9.1 Language Reference Dictionary, Volumes 1, 2 and 3
ISBN: N/A
EAN: N/A
Year: 2004
Pages: 704

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net