From 352cd84f602f3c9bf8ac86e1d7f8f14d5e6970db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Villemot?= <sebastien.villemot@ens.fr> Date: Wed, 13 Oct 2010 18:52:13 +0200 Subject: [PATCH] Explicit error message for 2nd and 3rd order purely forward models (cherry picked from commit 153f627dfe0eebaf6249a377af18a2d0c6035958) --- matlab/dr1.m | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/matlab/dr1.m b/matlab/dr1.m index 0c82a77abb..32b426343f 100644 --- a/matlab/dr1.m +++ b/matlab/dr1.m @@ -241,6 +241,10 @@ if M_.maximum_endo_lead == 0 return end +if M_.maximum_endo_lag == 0 && options_.order > 1 + error(['2nd and 3rd order approximation not implemented for purely forward models']) +end + %forward--looking models if nstatic > 0 [Q,R] = qr(b(:,1:nstatic)); -- GitLab