Can Matlab read an xls with multiple list values
4 views (last 30 days)
I would like my future Matlab program to read in a xls spreadsheet where some of the values have been selected from a list in said spreadsheet.
Before I continue to create the spreadsheet, I would like to know if Matlab would have any potential issues reading it due to the lists?
dpb on 1 Apr 2017
Edited: dpb on 1 Apr 2017
xslread is limited to reading a contiguous, rectangular area so if your values from the list aren't in such a pattern, "no can do" without additional effort. (It would seem superficially by reading the documentation that a named area selection would work, but on trying it in the past have discovered that while Matlab doesn't throw an error, all one gets if the area isn't contiguous is the UL-most corner of the region, not the whole thing.)
Generally, in Matlab if you must use Excel you'll be better off to just read a whole sheet and do whatever subsetting you need in memory. Otherwise, options are to create an export file format more amenable to data transport or use direct ActiveX/COM interfacing which turns into more of an Excel syntax question than Matlab after open the connection.