Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
dynare
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Dynare
dynare
Commits
9c92b20f
Commit
9c92b20f
authored
10 years ago
by
Stéphane Adjemian
Browse files
Options
Downloads
Patches
Plain Diff
Added unitary test.
parent
a5ea76d5
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
matlab/utilities/dseries/from.m
+17
-3
17 additions, 3 deletions
matlab/utilities/dseries/from.m
with
17 additions
and
3 deletions
matlab/utilities/dseries/from.m
+
17
−
3
View file @
9c92b20f
function
from
(
varargin
)
function
from
(
varargin
)
% --*-- Unitary tests --*--
% Copyright (C) 2014 Dynare Team
%
...
...
@@ -244,7 +244,7 @@ for i=1:number_of_variables
eval
(
sprintf
(
'%s = var;'
,
current_variable
));
end
end
variable_names
% Get the name of the assigned variable (with time index)
assignedvariablename
=
regexpi
(
EXPRESSION
(
1
:
equal_id
-
1
),
'\w*\(t\)|\w*\(t\-\d\)|\w*\(t\+\d\)|\w*\.\w*\(t\)|\w*\.\w*\(t\-\d\)|\w*\.\w*\(t\+\d\)'
,
'match'
);
if
isempty
(
assignedvariablename
)
...
...
@@ -421,4 +421,18 @@ function i = isassignedvariable(var,expr)
return
end
end
i
=
0
;
\ No newline at end of file
i
=
0
;
%@test:1
%$ try
%$ y = dseries(zeros(400,1),dates('1950Q1')) ;
%$ v = dseries(randn(400,1),dates('1950Q1')) ;
%$ u = dseries(randn(400,1),dates('1950Q1')) ;
%$ from 1950Q2 to 2049Q4 do y(t) = (1+.01*u(t))*y(t-1) + v(t)
%$ t(1) = 1;
%$ catch
%$ t(1) = 0;
%$ end
%$
%$ T = all(t);
%@eof:1
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment