%% Empty Strings in String Array
% Find strings with no characters in a string array and assign them a value.

str = string({'Amy','Charles','';...
            'Mark','','Sarah'})

%
% Return a logical array where the position of each element equal to 1 corresponds to the position of a string with no characters.

tf = str==''

%
% Replace the empty strings with a new value.

str(tf) = 'me'

% Copyright 2012 The MathWorks, Inc.