How to read multiple excel files with different names

조회 수: 22 (최근 30일)
Michela Gasperini
Michela Gasperini 2018년 12월 19일
답변: xi 2018년 12월 19일
Hi everyone, I have 41 excel files that I have to import to MATLAB. From these files I need to get the value of a specific cell (for every file the cell number and letter are the same). I would like to create an arrow containing the all the values from each of the file. Any idea how I can do it?
Thank you!!

답변 (1개)

xi
xi 2018년 12월 19일
you can use this commend to select multiple files from the same folder..
[files,path]=uigetfile('*.xlsx','multiselect','on')
and then use xlsread to access data in each file. and do whatever you want. see xlsread
for i=1:41
[~, ~, data{i}]=xlsread(fullfile(path,files{i}))
end

카테고리

Help CenterFile Exchange에서 Spreadsheets에 대해 자세히 알아보기

제품


릴리스

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by