Fixed bug.

aggregate was crashing in the absence of tags on the endogenous or exogenous variables.
time-shift
Stéphane Adjemian (Charybdis) 2019-07-19 16:51:16 +02:00
parent 2cfff70a64
commit 499481e889
1 changed files with 2 additions and 2 deletions

View File

@ -161,7 +161,7 @@ else
end
fprintf(fid, 'var\n');
for i=1:rows(elist)
if isempty(elist{i,2})
if size(elist,2)==1 || isempty(elist{i,2})
fprintf(fid, '\t%s\n', elist{i,1});
else
fprintf(fid, '\t%s %s\n', elist{i,1}, elist{i,2});
@ -180,7 +180,7 @@ if ~isempty(xlist)
fprintf(fid, '\n\n');
fprintf(fid, 'varexo\n');
for i=1:rows(xlist)
if isempty(xlist{i,2})
if size(xlist,2)==1 || isempty(xlist{i,2})
fprintf(fid, '\t%s\n', xlist{i,1});
else
fprintf(fid, '\t%s %s\n', xlist{i,1}, xlist{i,2});