I think it would be better to move the cellfun outside the validateattributes - i.e. have the validateattributes as the function being applied on each cell rather than putting cellfun inside validateattributes.
e.g.
validationFunc = @(signal), validateattributes( signal, { 'char' }, { },...
cellfun( validationFunc, signals )
(I haven't checked that syntax on command line, but that is the idea anyway and so far as I can see the syntax is fine, except I missed out your extra arguments for validateattributes that you can obviously add in. I never tend to use those extra arguments personally so just left them off for speed!)
Best Answer