Assuming you have the file name as a variable, I'll use myName:
myName = lower(myName);
idx = strfind(str,'composite');
if ~isempty(idx)
else
end
You need to find if 'Composite' is in the file name. strfind() returns the indices where it finds the match as a vector, if it doesn't find anything, it returns the empty vector. If you check whether or not the vector is empty, you can check whether or not 'Composite' is in the file name. I used lower() because strfind() is case sensitive. If case matters, you can just ignore the line