Prev: Optmizaing a vector of 1-D functions
Next: How to eliminate/replace values if accumulated sum in an arrayexceeds a certain limit
From: Thomas Ibbotson on 8 Apr 2010 13:48 I am currently finding files in a directory using the following code: re = 'some regular expression'; f = dir('.'); matchingFiles = f(cellfun(@(x) ~isempty(regexp(x, re, 'once')), {f.name})).name; Somehow I feel there must be a better way to do this. Does anyone have any suggestions? Tom |