subdivide numbers inside a file .xlsx
이전 댓글 표시
How can I divide the numbers into different columns in this attached .xlsx file?
filename = 'file.xlsx';
t = readtable(filename);
t(1:6,:)
채택된 답변
추가 답변 (2개)
Simpler:
C = readcell('file.xlsx');
M = str2double(split(C(6:end),', '))
T = array2table(M, 'VariableNames',split(C(5),', '))
Your data is stored in single cells of the xlsx. For example
-3.55882719e-02, -1.09321419e-02, 8.20557680e-03, 0.00000000e+00, 1.00000292e-01
is stored all as a single cell, not as seperate cells.
format long g
filename = 'file.xlsx';
temp = readcell(filename, 'headerlines', 5);
t = cell2mat(cellfun(@str2num, temp, 'uniform', 0))
카테고리
도움말 센터 및 File Exchange에서 Spreadsheets에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!