NAWRU State-Space Model
Posted: Thu Aug 31, 2017 11:09 am
This shows the construction of several different state-space models for estimating the NAWRU (Non-Accelerating Wage Rate of Unemployment) using unobserved components state-space models. Note well that, as written, this requires RATS 9.10f. (It uses some very recent additions to simplify the coding). The 2nd Edition of the State-Space/DSGE e-course covers these is (very) great detail.
The overall decomposition is U=N+G where U is the unemployment rate, N the NAWRU and G the unemployment gap. There are four different models tried for N:
None of the four NAWRU models is an ideal choice for a series like this. While the series has an overall upward movement, it's not a particularly strong trend. The program estimates the models with fully unconstrained variances for the components (other than non-negativity constraints). The log likelihood for the four models are almost identical even though the decompositions are dramatically different (see the graphs). In practice, this type of model can only be used with fairly tight constraints on the variances (upper bounds and possibly non-zero lower bounds). The ss_5_5.rpf program estimates the damped drift model with a constraint on the variance of the trend rate process, which produces something at least close to a reasonable decomposition (the final graph).
Tips and Tricks
This has four possible trend models, each with different parameters, some even with a different number of states. These all need to be combined with the cycle model to form the overall UC model. To simplify this, each of the trend models has a separate PARMSET and a separate FUNCTION. The PARMSET has its variables and standard constraints. The function computes the state-space system matrices given that. Because of the different forms, the system matrices include A (returned by the function), Z (some models need it), F, C and SW. The PARMSET and FUNCTIONS are put into a HASH keyed to a name for the model (such as "LocalLevel").
dec hash[parmset] nparms
newtype dlmfunc function[rect](vect*,vect*,rect*,symm*)
dec hash[dlmfunc] nfunc
The NEWTYPE instruction is new and not yet documented---it allows you to define a new type as a shorthand.
The NAWRUStart function takes the chosen model for the trend and standard model for the cycle and combines them by matrix concatenation. The DLM instruction
dlm(start=NAWRUStart(model),parmset=nparms(model)+cycleparms,$
presample=ergodic,a=adlm,f=fdlm,z=zdlm,c=cdlm,sw=swdlm,$
method=bfgs,y=lur,type=smooth,iters=500) / xstates vstates
has the same structure for each value of "model"---it calls NAWRUStart for the model to construct the overall system matrices (ADLM, FDLM, ...) and "adds" the proper PARMSET to the PARMSET for the cycle model.
The overall decomposition is U=N+G where U is the unemployment rate, N the NAWRU and G the unemployment gap. There are four different models tried for N:
- A local level model
- A damped "drift" model
- A damped trend model
- A local trend model
None of the four NAWRU models is an ideal choice for a series like this. While the series has an overall upward movement, it's not a particularly strong trend. The program estimates the models with fully unconstrained variances for the components (other than non-negativity constraints). The log likelihood for the four models are almost identical even though the decompositions are dramatically different (see the graphs). In practice, this type of model can only be used with fairly tight constraints on the variances (upper bounds and possibly non-zero lower bounds). The ss_5_5.rpf program estimates the damped drift model with a constraint on the variance of the trend rate process, which produces something at least close to a reasonable decomposition (the final graph).
Tips and Tricks
This has four possible trend models, each with different parameters, some even with a different number of states. These all need to be combined with the cycle model to form the overall UC model. To simplify this, each of the trend models has a separate PARMSET and a separate FUNCTION. The PARMSET has its variables and standard constraints. The function computes the state-space system matrices given that. Because of the different forms, the system matrices include A (returned by the function), Z (some models need it), F, C and SW. The PARMSET and FUNCTIONS are put into a HASH keyed to a name for the model (such as "LocalLevel").
dec hash[parmset] nparms
newtype dlmfunc function[rect](vect*,vect*,rect*,symm*)
dec hash[dlmfunc] nfunc
The NEWTYPE instruction is new and not yet documented---it allows you to define a new type as a shorthand.
The NAWRUStart function takes the chosen model for the trend and standard model for the cycle and combines them by matrix concatenation. The DLM instruction
dlm(start=NAWRUStart(model),parmset=nparms(model)+cycleparms,$
presample=ergodic,a=adlm,f=fdlm,z=zdlm,c=cdlm,sw=swdlm,$
method=bfgs,y=lur,type=smooth,iters=500) / xstates vstates
has the same structure for each value of "model"---it calls NAWRUStart for the model to construct the overall system matrices (ADLM, FDLM, ...) and "adds" the proper PARMSET to the PARMSET for the cycle model.