Skip to content
Snippets Groups Projects
Commit 3b3d753d authored by Stéphane Adjemian's avatar Stéphane Adjemian
Browse files

Modified @dynSeries/mtimes method so that dynSeries objects defined over...

Modified @dynSeries/mtimes method so that dynSeries objects defined over different non disjoint periods can be multiplied.
parent b955b20b
No related branches found
No related tags found
No related merge requests found
......@@ -55,14 +55,11 @@ if isa(B,'dynSeries') && isa(C,'dynSeries')
idC = 1:C.vobs;
end
end
if ~isequal(B.nobs,C.nobs)
error(['dynSeries::times: Cannot multiply ' inputname(1) ' and ' inputname(2) ' (wrong number of observations)!'])
end
if ~isequal(B.freq,C.freq)
error(['dynSeries::times: Cannot multiply ' inputname(1) ' and ' inputname(2) ' (frequencies are different)!'])
end
if ~isequal(B.init,C.init)
error(['dynSeries::times: Cannot multiply ' inputname(1) ' and ' inputname(2) ' (initial dates are different)!'])
if ~isequal(B.nobs,C.nobs) || ~isequal(B.init,C.init)
[B, C] = align(B, C);
end
A = dynSeries();
A.freq = B.freq;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment