https://github.com/cran/pracma
Tip revision: a7001ff1805634d18a10fa371b38dbe3e48f8c9e authored by HwB on 30 October 2011, 00:00:00 UTC
version 0.8.1
version 0.8.1
Tip revision: a7001ff
combs.R
##
## c o m b s . R Test Suite
##
combs <- pracma::combs
randcomb <- pracma::randcomb
identical(combs(2, 1), 2)
identical(combs(c(1, 2, 3), 2), matrix(rep(c(1, 2, 3), each = 2), 3, 2))
identical(nrow(combs(1:6, 4)), 15L)
all(c(1,2,3) %in% randcomb(c(1,2,3), 3))