textscan not reading file properly
1 回表示 (過去 30 日間)
古いコメントを表示
I have used textscan successfully in this manner for other files (different file extension). I am not sure why it does not work for this excel sheet (.xlsx). It is telling me that M = [0x1 double] [0x1 double].
clear
fid=fopen('data.xlsx');
M = textscan(fid,'%n%n')
fclose(fid);
Any help is appreciated. Thanks!
2 件のコメント
Walter Roberson
2013 年 7 月 2 日
Which MATLAB release are you using, and which operating system? If you are on MS Windows, which version of Excel do you have installed ?
回答 (2 件)
per isakson
2013 年 7 月 2 日
編集済み: per isakson
2013 年 7 月 2 日
Could it be that the cells in Excel are defined as right-justified text? Try
[num,txt,raw] = xlsread('data.xlsx')
and inspect all three outputs.
Which versions of Excel and Matlab do you use?
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Spreadsheets についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!