Skip to content

Instantly share code, notes, and snippets.

@myw
Created April 11, 2012 20:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save myw/2362085 to your computer and use it in GitHub Desktop.
Save myw/2362085 to your computer and use it in GitHub Desktop.
More powerful anonymous functions in Matlab
ev = @(varargin) cellfun(@feval, varargin, 'UniformOutput', false);
% Ex.: super_anon = @(a, b, c) ev(...
% @() disp(a), ...
% @() plot(1:b, cos(1:b)), ...
% @() disp(c) )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment