MATLAB: How to figure out if an array is ordinary or cell cell arrayMATLAB In my code, variable (A) can be either an ordinary array or cell array. How can I do following If (A) is an ordinary array then do nothing If (A) is a cell array then cell2mat(A) Best Answer tf = iscell(A);if tf == 1 A =cell2mat(A)end Related SolutionsMATLAB: Delete empty [] {1×7 cell} {1×2 cell} z(cellfun('isempty',z))=[] MATLAB: How to count the 1X1 cells in a cell array a=cellfun(@numel,Out)sum(a==1) Related QuestionFor Loop for CellHow to repeat a cellManipulation of a cell array-
Best Answer