%% Members of Char and Cell Array of Character Vectors
% Create a character vector, A, and a cell array of character vectors, B.

A = ['cat';'dog';'fox';'pig'];
B = {'dog','cat','fish','horse'};

%
% Determine which character vectors of A are also in B.

[Lia,Locb] = ismember(A,B)

% Copyright 2012 The MathWorks, Inc.