Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Dóra Kocsis
dynare
Commits
64ddca51
Commit
64ddca51
authored
Mar 13, 2013
by
MichelJuillard
Browse files
dynSeries: making possible to concatanate empty series; fixing bugs
parent
ebf93d67
Changes
2
Hide whitespace changes
Inline
Side-by-side
matlab/@dynSeries/horzcat.m
View file @
64ddca51
...
...
@@ -58,11 +58,11 @@ function a = horzcat(varargin)
%
Original
author
:
stephane
DOT
adjemian
AT
univ
DASH
lemans
DOT
fr
if
nargin
==
0
||
nargin
==
1
error
(
'
dynSeries
::
horzcat
:
I
need
at
least
two
input
arguments
!
'
)
e
nd
if
nargin
==
2
if
nargin
==
0
a
=
DynSeries
();
e
lseif
nargin
==
1
a
=
varargin
{
1
};
else
if
nargin
==
2
a
=
horzcat2
(
varargin
{
1
},
varargin
{
2
});
else
a
=
horzcat2
(
varargin
{
1
},
varargin
{
2
});
...
...
matlab/@dynSeries/private/horzcat2.m
View file @
64ddca51
...
...
@@ -108,5 +108,6 @@ else
c
.
data
=
[
c
.
data
;
NaN
(
b_last_date
-
c_last_date
,
c
.
vobs
)];
end
a
.
data
=
[
b
.
data
,
c
.
data
];
a
.
time
=
unique
([
b
.
time
,
c
.
time
]);
end
\ No newline at end of file
a
.
time
=
unique
(
b
.
time
.
append
(
c
.
time
));
end
a
.
nobs
=
size
(
a
.
data
,
1
);
\ No newline at end of file
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment