I have multiple csv files that need to be imported to later extract certain columns to write new files. However the code below doesnt return the column I need (column 1) I need the code to create a matrix "Time" for every file

조회 수: 1 (최근 30일)
folder= 'H:\Matlab\CSV\Processed_csv_Type3';
d = dir([folder '\*.csv']);
for i=1:length(d)
m{i}=csvread(d(i).name); % put into cell array
Time{i} =m{i(:,1)};
end

채택된 답변

KSSV
KSSV 2016년 12월 2일
folder= 'H:\Matlab\CSV\Processed_csv_Type3';
d = dir([folder '\*.csv']);
for i=1:length(d)
m{i}=csvread(d(i).name); % put into cell array
Time{i} =m{i}(:,1);
end

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by