...
 
Commits (2)
...@@ -42,7 +42,7 @@ if ~all(cellfun(@isempty, struct2cell(o.regression))) ...@@ -42,7 +42,7 @@ if ~all(cellfun(@isempty, struct2cell(o.regression)))
savedoutput = savedoutput(~cellfun('isempty', savedoutput)); savedoutput = savedoutput(~cellfun('isempty', savedoutput));
for i=1:length(savedoutput) for i=1:length(savedoutput)
if exist(sprintf('%s.%s', basename, lower(savedoutput{i}))) if exist(sprintf('%s.%s', basename, lower(savedoutput{i})))
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i}); o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i});
end end
...@@ -57,7 +57,7 @@ if ~all(cellfun(@isempty, struct2cell(o.x11))) ...@@ -57,7 +57,7 @@ if ~all(cellfun(@isempty, struct2cell(o.x11)))
savedoutput = savedoutput(~cellfun('isempty', savedoutput)); savedoutput = savedoutput(~cellfun('isempty', savedoutput));
for i=1:length(savedoutput) for i=1:length(savedoutput)
if exist(sprintf('%s.%s', basename, lower(savedoutput{i}))) if exist(sprintf('%s.%s', basename, lower(savedoutput{i})))
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i}); o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i});
end end
...@@ -72,7 +72,7 @@ if ~all(cellfun(@isempty, struct2cell(o.forecast))) ...@@ -72,7 +72,7 @@ if ~all(cellfun(@isempty, struct2cell(o.forecast)))
savedoutput = savedoutput(~cellfun('isempty', savedoutput)); savedoutput = savedoutput(~cellfun('isempty', savedoutput));
for i=1:length(savedoutput) for i=1:length(savedoutput)
if exist(sprintf('%s.%s', basename, lower(savedoutput{i}))) if exist(sprintf('%s.%s', basename, lower(savedoutput{i})))
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
initdate = num2str(tmp.data(1,1)); % wrong in series initdate = num2str(tmp.data(1,1)); % wrong in series
t = o.y.dates; t = o.y.dates;
name = strsplit(tmp.textdata{1},'\t'); name = strsplit(tmp.textdata{1},'\t');
...@@ -97,7 +97,7 @@ if ~all(cellfun(@isempty, struct2cell(o.transform))) ...@@ -97,7 +97,7 @@ if ~all(cellfun(@isempty, struct2cell(o.transform)))
savedoutput = savedoutput(~cellfun('isempty', savedoutput)); savedoutput = savedoutput(~cellfun('isempty', savedoutput));
for i=1:length(savedoutput) for i=1:length(savedoutput)
if exist(sprintf('%s.%s', basename, lower(savedoutput{i}))) if exist(sprintf('%s.%s', basename, lower(savedoutput{i})))
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i}); o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i});
end end
...@@ -112,7 +112,7 @@ if ~all(cellfun(@isempty, struct2cell(o.outlier))) ...@@ -112,7 +112,7 @@ if ~all(cellfun(@isempty, struct2cell(o.outlier)))
savedoutput = savedoutput(~cellfun('isempty', savedoutput)); savedoutput = savedoutput(~cellfun('isempty', savedoutput));
for i=1:length(savedoutput) for i=1:length(savedoutput)
if exist(sprintf('%s.%s', basename, lower(savedoutput{i}))) if exist(sprintf('%s.%s', basename, lower(savedoutput{i})))
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
if lower(savedoutput{i}) == 'fts' if lower(savedoutput{i}) == 'fts'
header = strjoin(tmp.textdata(1)); header = strjoin(tmp.textdata(1));
...@@ -146,7 +146,7 @@ if ~all(cellfun(@isempty, struct2cell(o.slidingspans))) ...@@ -146,7 +146,7 @@ if ~all(cellfun(@isempty, struct2cell(o.slidingspans)))
savedoutput = savedoutput(~cellfun('isempty', savedoutput)); savedoutput = savedoutput(~cellfun('isempty', savedoutput));
for i=1:length(savedoutput) for i=1:length(savedoutput)
if exist(sprintf('%s.%s', basename, lower(savedoutput{i}))) if exist(sprintf('%s.%s', basename, lower(savedoutput{i})))
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
header = strjoin(tmp.textdata(1)); header = strjoin(tmp.textdata(1));
header = strsplit(header, {'\t'}); header = strsplit(header, {'\t'});
...@@ -167,7 +167,7 @@ if ~all(cellfun(@isempty, struct2cell(o.identify))) ...@@ -167,7 +167,7 @@ if ~all(cellfun(@isempty, struct2cell(o.identify)))
savedoutput = savedoutput(~cellfun('isempty', savedoutput)); savedoutput = savedoutput(~cellfun('isempty', savedoutput));
for i=1:length(savedoutput) for i=1:length(savedoutput)
if exist(sprintf('%s.%s', basename, lower(savedoutput{i}))) if exist(sprintf('%s.%s', basename, lower(savedoutput{i})))
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
header = strjoin(tmp.textdata(3,1)); header = strjoin(tmp.textdata(3,1));
header = strsplit(header, {'\t'}); header = strsplit(header, {'\t'});
...@@ -194,7 +194,7 @@ if ~all(cellfun(@isempty, struct2cell(o.check))) ...@@ -194,7 +194,7 @@ if ~all(cellfun(@isempty, struct2cell(o.check)))
if lower(savedoutput{i}) == 'ac2' if lower(savedoutput{i}) == 'ac2'
o.results.(savedoutput{i}) = fileread(sprintf('%s.ac2', basename)); o.results.(savedoutput{i}) = fileread(sprintf('%s.ac2', basename));
else else
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
header = strjoin(tmp.textdata(1,1)); header = strjoin(tmp.textdata(1,1));
header = strsplit(header, {'\t'}); header = strsplit(header, {'\t'});
...@@ -217,7 +217,7 @@ if ~all(cellfun(@isempty, struct2cell(o.force))) ...@@ -217,7 +217,7 @@ if ~all(cellfun(@isempty, struct2cell(o.force)))
savedoutput = savedoutput(~cellfun('isempty', savedoutput)); savedoutput = savedoutput(~cellfun('isempty', savedoutput));
for i=1:length(savedoutput) for i=1:length(savedoutput)
if exist(sprintf('%s.%s', basename, lower(savedoutput{i}))) if exist(sprintf('%s.%s', basename, lower(savedoutput{i})))
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i}); o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i});
end end
...@@ -232,7 +232,7 @@ if ~all(cellfun(@isempty, struct2cell(o.spectrum))) ...@@ -232,7 +232,7 @@ if ~all(cellfun(@isempty, struct2cell(o.spectrum)))
savedoutput = savedoutput(~cellfun('isempty', savedoutput)); savedoutput = savedoutput(~cellfun('isempty', savedoutput));
for i=1:length(savedoutput) for i=1:length(savedoutput)
if exist(sprintf('%s.%s', basename, lower(savedoutput{i}))) if exist(sprintf('%s.%s', basename, lower(savedoutput{i})))
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
header = strjoin(tmp.textdata(1,1)); header = strjoin(tmp.textdata(1,1));
header = strsplit(header, {'\t'}); header = strsplit(header, {'\t'});
...@@ -252,7 +252,7 @@ if ~all(cellfun(@isempty, struct2cell(o.seats))) ...@@ -252,7 +252,7 @@ if ~all(cellfun(@isempty, struct2cell(o.seats)))
savedoutput = savedoutput(~cellfun('isempty', savedoutput)); savedoutput = savedoutput(~cellfun('isempty', savedoutput));
for i=1:length(savedoutput) for i=1:length(savedoutput)
if exist(sprintf('%s.%s', basename, lower(savedoutput{i}))) if exist(sprintf('%s.%s', basename, lower(savedoutput{i})))
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i}); o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i});
end end
...@@ -271,7 +271,7 @@ if ~all(cellfun(@isempty, struct2cell(o.x11regression))) ...@@ -271,7 +271,7 @@ if ~all(cellfun(@isempty, struct2cell(o.x11regression)))
if lower(savedoutput{i}) == 'xrc' if lower(savedoutput{i}) == 'xrc'
o.results.out = fileread(sprintf('%s.xrc', basename)); o.results.out = fileread(sprintf('%s.xrc', basename));
else else
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i}); o.results.(savedoutput{i}) = dseries(data(:,2), o.y.init, savedoutput{i});
end end
...@@ -306,7 +306,7 @@ if ~all(cellfun(@isempty, struct2cell(o.estimate))) ...@@ -306,7 +306,7 @@ if ~all(cellfun(@isempty, struct2cell(o.estimate)))
end end
o.results.(savedoutput{i}) = fileread(sprintf('%s.estx', basename)); o.results.(savedoutput{i}) = fileread(sprintf('%s.estx', basename));
else else
tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i}))); tmp = importdata(sprintf('%s.%s', basename, lower(savedoutput{i})), '\t');
data = tmp.data; data = tmp.data;
end end
......
...@@ -42,7 +42,7 @@ end ...@@ -42,7 +42,7 @@ end
clear file basename; clear file basename;
save tmp__dataSet__; save tmp__dataSet__.mat;
[freq, init, data, varlist, tex, ops, tags] = load_mat_file_data('tmp__dataSet__.mat'); [freq, init, data, varlist, tex, ops, tags] = load_mat_file_data('tmp__dataSet__.mat');
......