taking the average of data from 500 different files
조회 수: 1 (최근 30일)
이전 댓글 표시
Hi,
I have 500 different files in sequential filenames in the following format: datafile_XX.mat
All of these files contain a matrix that is of size n x 8. n is changing per file. but there are 8 columns total.
I want to take the average of the first 400 rows of each file. How do i load all of these files efficiently?
댓글 수: 0
채택된 답변
the cyclist
2015년 12월 11일
for ni = 1:500
filename = sprintf('datafile_%03i.mat',ni);
load(filename)
% Process your stuff here
end
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Structures에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!