Vignettes and other documentation
Vignettes from package 'permutations'
permutations::permutations
A vignette for the magic package
PDF
source
R code