Investment Studio > Expressions > Functions > Math & Trig > COMBIN
float combin(integer n, integer k)
Returns the number of combinations of k items which can be formed from a set of n >= k items. k and n must be natural numbers (i.e. > 0).
A combination is any set of k items, without regard to their internal order: the set {1, 2} is the same as {2, 1}. If internal order is important, use the permut (permutation) function instead:
permut(n, k) = combin(n, k) * fact(k)
Example
The number of possible 10-stock portfolios which can be formed from the 100 components of the S&P 100 (without regard to order or stock weightings) is
=combin(100, 10)
or 17310309456440. That's 17.3 trillion, which is why investment software and fast computers are good to have.
See also binomdist, critbinom, fact, factdouble, hypgeomdist, negbinomdist, permut.