Excel reading - xlsread

6 ビュー (過去 30 日間)
ben harper
ben harper 2011 年 5 月 17 日
Hello i want to read some data from Excel worksheet. When i use "xlsread" some of the cells isn't readen by Matlab. For example a,b,c,d, etc. columns (4 to 11th columns)can be read, but name date and time columns (first three columns) can't be read in my example below.
How can i fix this without changing so much in excel worksheet?

採用された回答

Andy
Andy 2011 年 5 月 17 日
Use the third output of xlsread:
[data, txt, raw] = xlsread(...);
The "raw" output is a cell array which contains all of your data.
  3 件のコメント
Walter Roberson
Walter Roberson 2011 年 5 月 27 日
Reputation depends upon human subjectivity, and so is probably not suitable for a bot contest.

サインインしてコメントする。

その他の回答 (1 件)

Oleg Komarov
Oleg Komarov 2011 年 5 月 17 日
Use the second output of xlsread.
[data, text] = xlsread(...);
The first three columns and the first row is interpreted as char type and you cannot mix doubles with chars.

Community Treasure Hunt

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

Start Hunting!

Translated by