R/ternary.apply.R

Defines functions ternary.apply

Documented in ternary.apply

ternary.apply <-
function(grid, f, ...)
{
	f = match.fun(f)
	abc = grid[,letters[1:3]]
	g = function(i) f(abc[i,], ...)
	unlist(lapply(1:nrow(grid), g))
}

Try the trifield package in your browser

Any scripts or data that you put into this service are public.

trifield documentation built on May 29, 2017, 11:44 p.m.