I have a cell array (x) where in this case there is no value in one of the cell matrix. I want to add a -1 value in the matrix as a way of 'place-holding' that column. I've tried these approaches:
emptyCells = cellfun('isempty',x);x(emptyCells) = -1;x(isnan([x{:}]))={-1}x(cellfun(@isnan,x))={-1}
Any help would be greatly appreciated.
Best Answer