I have the following array:-
dir=['E','B','R']
I want to find the index of the elemen 'E'.
>> find(dir=='E')
ans =
1
But i want to do the same for an array of strings rather than array of characters like:
dir=['E','G','T','BR']
But there is an error to find 'BR'. I want the output to be 4.
>> find(dir=='BR')
Error using ==
Matrix dimensions must agree.
How to work-around this error?