How to import Excel file including empty cells?

18 views (last 30 days)
Yoshi
Yoshi on 20 Oct 2013
Answered: Image Analyst on 20 Oct 2013
I want to know the methods to import Excel file including empty cells? I am using Matlab R2013a student evaluation version on Windows and a new one in using the Matlab. I have checked several website and tried as the followings:
(1) Determine the data file size first and read data later. SzA = size(A) DimsA = ndims(A)
But the I have received an error message, "Error: An array for multiple LHS assignment cannot contain LEX_TS_NUMBER."
(2) Importing and Exporting Data(<http://people.duke.edu/~jmp33/matlab/importing_data.html>) seems to be nice information, I tried to use the function, dat=nan(size(raw)); but columns contain empty cells cannot displayed on the Matlab while only the culumns with full data cells are shown on the Matlab after reading the Excel file using the exsread function.
Looking forward to advice and information. Yoshi

Answers (1)

Image Analyst
Image Analyst on 20 Oct 2013
You cannot import empty cells. They are not defined. In older versions of Excel there could be as many as 256*16384 cells, and I think the later versions may be infinite or much larger. You would not want to import all empty cells in Excel even if you could.

Categories

Find more on Data Import from MATLAB in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!