view general/funutils/@function_handle/select.m @ 61:eff6bddf82e3 tip

Finally implemented perceptual brightness thing.
author samer
date Sun, 11 Oct 2015 10:20:42 +0100
parents 03694e5c8365
children
line wrap: on
line source
% select - Filter cell array with boolean test
%
% select :: (A->bool), {[N]->A} -> {[M]->A}.
% select :: (A->bool), {[1,N]->A} -> {[1,M]->A}.
%
% eg, select(@iseven,{1,2,3,4}) = {2,4}
function Y=select(fn,X), Y=cellfilt(fn,X);