I have a 435x1 cell array whose elements are either 'y', 'n', or '?'. I want to find which indices are equal to 'y'.
With normal arrays, I just use the find function. But I can't use that with cell arrays because eq is not defined for type cell.
I think I can go through each element and do
for index=1:size(cell_array,1)
if cell_array{index} == 'y'
%add index to some array of indices
end
end
But is there a vectorized way to go through the array and find indices contain elements that are equal to 'y'? Any help is appreciated.