load files containing part of a string in the file name and the load that file
13 views (last 30 days)
Im kind of new to matlab and I have the following problem: I have many files as .mat files with the following names, all in one folder. So what I want to do is to load all BASF files first and save them into a new BASF folder and then load all BIOG files and save them into a new BIOG folder.
So far, this is what I have tried :
basf(cellfun(@(basf) isempty(basf),basf))=; %get rid of empty cell arrays
The problem is when I try to load all the files included in the basf cell array it says " Argument must contain a string". So I dont know how to make matlab load all the files that contain BASF or BIOG in ther file names. Could you please help me? Thank you so much! Lourdes