Commit befdf3f6 authored by Stéphane Adjemian's avatar Stéphane Adjemian

Merge pull request #2 from houtanb/master

fix test for dates creation when creating annual dates
parents 4c156241 bd73f401
classdef dates<handle
% Copyright (C) 2014 Dynare Team
% Copyright (C) 2014-2015 Dynare Team
%
% This code is free software: you can redistribute it and/or modify
% it under the terms of the GNU General Public License as published by
......@@ -88,7 +88,7 @@ classdef dates<handle
o.freq = varargin{1};
end
if isequal(o.freq, 1)
if (isnumeric(varargin{2}) && isvector(varargin{2}) && isint(varargin{2}))
if (isnumeric(varargin{2}) && isvector(varargin{2}) && all(isint(varargin{2})))
o.time = [varargin{2}, ones(length(varargin{2}),1)];
o.ndat = size(o.time,1);
return
......@@ -263,4 +263,4 @@ end % classdef
%$ end
%$
%$ T = all(t);
%@eof:8
\ No newline at end of file
%@eof:8
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