Commit 7a8b4073 authored by Ferhat Mihoubi's avatar Ferhat Mihoubi
Browse files

Adds csv files in the file formats supported by datafile

parent f16a8b16
......@@ -102,6 +102,26 @@ switch (extension)
end
dyn_data_01(:,dyn_i_01) = dyn_tmp_01;
end
case '.csv'
[freq,init,data,varlist] = load_csv_file_data(fullname);
disp('size(data)');
size(data)
% for i=1:length(varlist)
% if isnan(varlist)
% varlist(1,i) = ' ';
% end
% end
%var_names_01 = deblank(var_names_01);
for dyn_i_01=1:var_size_01
iv = strmatch(deblank(var_names_01(dyn_i_01,:)),varlist,'exact') + 1;
dyn_tmp_01 = [data(2:end,iv)]';
if length(dyn_tmp_01) > dyn_size_01 && dyn_size_01 > 0
cd(old_pwd)
error('data size is too large')
end
dyn_data_01(:,dyn_i_01) = dyn_tmp_01;
end
otherwise
cd(old_pwd)
error(['Unsupported extension for datafile: ' extension])
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment