MATLAB: Cell comparing logic output

cell arrays

Friends,
I want to compare 2 cell arrays and if all characters are similar I want to generate 1 as output and else 0 as the output. but i could not find a simple compare function for cell arrays. pls help me on this ? Thanks in advance.

Best Answer

all( cellfun( @(x,y) isequal( x, y ), cellArray1, cellArray2 ) )
should do the job I think.
Related Question