R/tableTools.R

Defines functions table.nosort

# tableTools.R -- hopefully faster verison of counting 1-D table entries

table.nosort <- function(x) {

	s <- x[ ! duplicated(x)]
	wh <- match( x, s)
	cnt <- base::tabulate(wh)
	names(cnt) <- s
	cnt
}
robertdouglasmorrison/DuffyTools documentation built on May 6, 2024, 8:26 p.m.