Put excel collumns in an array
1 次查看(过去 30 天)
显示 更早的评论
Hello !
I have never used excel parser in Matlab. I have an excel file which have 3 columns. And i would like to save all elements of column 2 in an array and all elements of column 3 in an other array. How can i browse the excel file column by column and then line by line ?
Thank you !
0 个评论
采纳的回答
Saurav Roy
2020-4-28
Hey !
I hope this is what you are looking for....
% Read Excel Sheet
[~,~,data] = xlsread('Add path to the excel file (.xlsx)');
% Save columns
arraycolumn2 = data(:,2); % Parse column 2
arraycolumn3 = data(:,3); % Parse column 3
更多回答(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!