Commit Graph

71 Commits (e9ffb16ec62b8e6cba2ca1dc84e8c4c65d8a45f0)

Author SHA1 Message Date
Stéphane Adjemia (Scylla) 7d2d0d6590
Added the possibility to estimate the share of optimizing agents by iterative OLS (PAC). 2018-11-21 15:07:15 +01:00
Stéphane Adjemian(Charybdis) 2518cd9884 Raise error of an optimization algorithm is not available. 2018-09-13 16:16:07 +02:00
Stéphane Adjemian(Charybdis) 2437d7034e Give access to more than one optimizer in PAC estimation (NLS).
Default is to use csminwel optimizer (because it seems to do the job and does
not rely on the Mathworks toolbox).
2018-09-13 16:15:52 +02:00
Stéphane Adjemian(Charybdis) 6815624a6a Fixed bug.
Growth neutrality correction was applied twice.
2018-09-12 15:41:07 +02:00
Stéphane Adjemian(Charybdis) 0f3678ec4a Fixed ordering of variables in error correction term of PAC equation
PAC equation has to be written as

diff(x) = a0*(xstar(-1)-x(-1)) + a1*diff(x(-1)) + ... + ap*diff(x(-p)) + PAC_EXPECTATION(pacmodelname) + ...;

In the error correction term, a0*(xstar(-1)-x(-1)), we must have the difference
between the target (the trend xstar(-1)) and the level of the endogenous
variable (x(-1)). To ensure stability around the trend, the parameter a0 needs
to be positive.

REMARKS

 [1] In the TREND_COMPONENT_MODEL the error correction terms are written in
 reverse order, ie as the difference betwwen the level of the endogenous
 variable and the trend variable.

 [2] In the estimation routine we do not constrain a0 to be positive, but is
 would surely help to satisfy this condition in the initial condition.
2018-09-06 22:07:31 +02:00
Stéphane Adjemian(Charybdis) 74ef4d2131 Cosmetic change. 2018-09-06 13:40:43 +02:00
Stéphane Adjemian(Charybdis) 5d8a1feda4 Fixed regular expression.
Data matrices were not correcty lagged for lags>1. This commit fixes the
inconsistencies (in terms of residuals) between Iterative OLS and NLS routines.
2018-09-06 13:40:27 +02:00
Stéphane Adjemian(Charybdis) 940c970ff3 Use same range in NLS and Iterative OLS.
The range option is the range of data considered for the right hand side variable.
2018-09-04 09:40:47 +02:00
Stéphane Adjemian(Charybdis) 6e1d06bddc Display SSR in Iterative OLS. 2018-09-03 18:01:59 +02:00
Stéphane Adjemian(Charybdis) 8b1b1273c3 Fixed correction for growth neutrality.
Also added the possibility to use an endogenous variable for growth.
2018-09-03 17:57:10 +02:00
Stéphane Adjemian(Charybdis) fde103d5f4 Removed debugging display. 2018-09-03 17:55:55 +02:00
Stéphane Adjemian(Charybdis) a207550680 Fixed error correction term. 2018-09-03 17:53:01 +02:00
Stéphane Adjemia (Scylla) e1b2b80d64 Small efficiency change. 2018-08-29 17:42:49 +02:00
Stéphane Adjemia (Scylla) d23d1a470b Added the possibility to estimate PAC_EQUATION with iterative ols and non constant growth. 2018-08-29 17:42:04 +02:00
Stéphane Adjemia (Scylla) 30b34c4323 Small efficiency changes. 2018-08-29 16:15:52 +02:00
Stéphane Adjemia (Scylla) 2b6ee881a4 Efficiency changes. 2018-08-22 11:49:15 +02:00
Stéphane Adjemia (Scylla) 442a70e905 Added missing semicolon. 2018-08-21 21:56:01 +02:00
Stéphane Adjemia (Scylla) 7d6296f7a6 Fixed bug introduced by 42bba08887. 2018-08-17 21:42:09 +02:00
Stéphane Adjemian(Charybdis) 42bba08887 Make the code robust to the order of declaration of the estimated parameters. 2018-08-15 22:03:33 +02:00
Stéphane Adjemian(Charybdis) 0edebbe5d7 Added Iterative OLS routine for PAC equation. 2018-07-23 16:12:46 +02:00
Stéphane Adjemian(Charybdis) cd9410644f Moved PAC estimation routine (NLS). 2018-07-16 16:30:07 +02:00