From 153f627dfe0eebaf6249a377af18a2d0c6035958 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Villemot?= Date: Wed, 13 Oct 2010 18:52:13 +0200 Subject: [PATCH] Explicit error message for 2nd and 3rd order purely forward models --- matlab/dr1.m | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/matlab/dr1.m b/matlab/dr1.m index 19fac2143..3c1722d1e 100644 --- a/matlab/dr1.m +++ b/matlab/dr1.m @@ -254,6 +254,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));