Tag: combination

SAS Combinatorial Functions: Snippets

1. Permutation and Combination data _null_;     n = 5;     r = 2;    *the factorial of a number;    fact=fact(n);    *for positive integers, fact(n) = gamma(n+1);    gamm=gamma(n + 1);    *C(n,r): number of combinations of n objects selected r ;    *n! / [r!(n-r)!];    comb1 = comb(n,r);    comb2 = […]