MATLAB Function Reference |
Strip trailing blanks from end of string
Syntax
Description
str = deblank(
removes the trailing blanks from the end of a character string str
)
str
.
c = deblank(c),
when c
is a cell array of strings, applies deblank
to each element of c
.
The deblank
function is useful for cleaning up the rows of a character array.
Examples
A{1,1} = 'MATLAB '; A{1,2} = 'SIMULINK '; A{2,1} = 'Toolboxes '; A{2,2} = 'The MathWorks '; A = 'MATLAB ' 'SIMULINK ' 'Toolboxes ' 'The MathWorks ' deblank(A) ans = 'MATLAB' 'SIMULINK' 'Toolboxes' 'The MathWorks'
deal | debug |
© 1994-2005 The MathWorks, Inc.