logical
1
Use char to convert back to a padded character array.
chr = char(celldata)
chr =
3×13 char array
'Allison Jones'
'Development '
'Phoenix '
For more information on cell arrays, see “Access Data in Cell Array” on page 12-5.
Functions for Cell Arrays of Character Vectors
This table describes the MATLAB functions for working with cell arrays of character
vectors.
Function Description
cellstr Convert a character array to a cell array of character vectors.
char Convert a cell array of character vectors to a character array.
string Starting in R2016b, convert a cell array of character vectors to a
string array.
deblank Remove trailing blanks from a character array.
iscellstr Return true for a cell array of character arrays.
sort Sort elements in ascending or descending order.
strcat Concatenate character arrays or cell arrays of character arrays.
strcmp Compare character arrays or cell arrays of character arrays.
You can also use the following set functions with cell arrays of character vectors.
Function Description
intersect Set the intersection of two vectors.
6 Characters and Strings