How to save sub-fields of a structure in txt file format with the same filenames in a loop
1 回表示 (過去 30 日間)
% folder = uigetdir();
% fileList = dir(fullfile(folder, '*.bmp'));
files = dir('*.lvm');
basename = sprintf('Metal_%d', K);
filename = [basename '.lvm'];
outfile = [basename '.mat'];
signal= [basename '.txt'];
if exist(filename, 'file') == 0
data.(basename) = lvm_import(filename, 1);
%save(outfile, '-struct', 'data')
Here is my code above. I was trying to save the data sub-filed having an order 204800x2 in text file in a loop. There are 121 structures generated by the code.
Kindly assit as soon as you ca.