2 %>@brief File list getter (not recursive)
5 %> @param wild =
'*'. E.g.
'*.mat'
6 %> @param patt_match (regular expression) If specified, directories will have to match
this pattern
7 %> @param patt_exclude (regular expression) If specified, directories will have NOT TO match
this pattern
9 function names =
getfiles(wild, patt_match, patt_exclude)
20 flag_match = ~isempty(patt_match);
21 flag_exclude = ~isempty(patt_exclude);
27 names = names(cellfun(@(x) ~isempty(x), regexp(names, patt_match,
'start')));
30 names = names(cellfun(@isempty, regexp(names, patt_exclude,
'start')));
function getfiles(in wild, in patt_match, in patt_exclude)