I want to capture everything except the tokens:
name, '_' and '.iv2'
'A7122_60a.iv2' 'A7122_60b.iv2' 'A7122_70a.iv2' 'A7122_70b.iv2' 'A7122_90a.iv2' 'A7122_90b.iv2' 'A7122_100.iv2' 'A7122_120.iv2'
I do this:
str=regexp(filename, [ '(?:[^' name '_])\w*(?:[^.iv2])' ], 'match');
And the answer is the following!
I don't understand why regexp has a different behavior for i.e. in filename(1) and filename(3)
No products are associated with this question.
You can use:
regexprep( filename, [ name, '_|.iv2'], '')
regexp( filename, [ name, '_(\w*).iv2'], 'tokens')