scieee AI-readable full text Open interactive document viewer

Handling structural break points in NEMO

Kravik, Erling Motzfeldt,Paulsen, Kenneth Sæterhagen

Abstract

EconStor is a publication server for scholarly economic literature, provided as a non-commercial public service by the ZBW.

Full text

Kravik, Erling Motzfeldt; Paulsen, Kenneth Sæterhagen Research Report Handling structural break points in NEMO Staff Memo, No. 2/2020 Provided in Cooperation with: Norges Bank, Oslo Suggested Citation: Kravik, Erling Motzfeldt; Paulsen, Kenneth Sæterhagen (2020) : Handling structural break points in NEMO, Staff Memo, No. 2/2020, ISBN 978-82-8379-137-2, Norges Bank, Oslo, https://hdl.handle.net/11250/2655713 This Version is available at: https://hdl.handle.net/10419/246142 Standard-Nutzungsbedingungen: Die Dokumente auf EconStor dürfen zu eigenen wissenschaftlichen Zwecken und zum Privatgebrauch gespeichert und kopiert werden. Sie dürfen die Dokumente nicht für öffentliche oder kommerzielle Zwecke vervielfältigen, öffentlich ausstellen, öffentlich zugänglich machen, vertreiben oder anderweitig nutzen. Sofern die Verfasser die Dokumente unter Open-Content-Lizenzen (insbesondere CC-Lizenzen) zur Verfügung gestellt haben sollten, gelten abweichend von diesen Nutzungsbedingungen die in der dort genannten Lizenz gewährten Nutzungsrechte. Terms of use: Documents in EconStor may be saved and copied for your personal and scholarly purposes. You are not to copy documents for public or commercial purposes, to exhibit the documents publicly, to make them publicly available on the internet, or to distribute or otherwise use the documents in public. If the documents have been made available under an Open Content Licence (especially Creative Commons Licences), you may exercise further usage rights as specified in the indicated licence. https://creativecommons.org/licenses/by-nc-nd/4.0/deed.no STAFF MEMO Handling structural break points in NEMO NO 2 | 2020 ERLING MOTZFELDT KRAVIK AND KENNETH SÆTERHAGEN PAULSEN NORGES BANK STAFF MEMO NR 2 | 2020 HANDLING STRUCTURAL BREAK POINTS IN NEMO Staff Memo inneholder utredninger og dokumentasjon skrevet av Norges Banks ansatte og andre forfattere tilknyttet Norges Bank. Synspunkter og konklusjoner i arbeidene er ikke nødvendigvis representative for Norges Bank © 2020 Norges Bank Det kan siteres fra eller henvises til dette arbeid, gitt at forfatter og Norges Bank oppgis som kilde. ISSN 1504-2596 (online) ISBN 978-82-8379-137-2 (online) Handling structural break points in NEMO∗ Erling Motzfeldt Kravik†Kenneth Sæterhagen Paulsen‡ February 7, 2020 Abstract This paper documents a new feature in Norges Bank’s policy model NEMO, namely the ability to handle structural break points, i.e. shifts in one or more parameter values at a specific point in time. This property is introduced to enable the model to answer new policy-relevant questions, such as the effect of changes in the inflation target and the effect of a sudden drop in the expected long-term oil price. We document the theoretical solution technique and illustrate its usage through a practical example. Additionally, we present a procedure for estimating break points. Our results indicate that including structural shifts is important when interpreting data. Neglecting structural shifts can lead to wrong interpretations of history, which, potentially, could also affect forecast performance. ∗This staff memo should not be reported as representing the views of Norges Bank. The views expressed are those of the authors and do not necessarily reflect those of Norges Bank. We would like to thank Karsten R. Gerdrup, Ørjan Robstad and our colleagues at the Monetary Policy Department of Norges Bank for their helpful comments and suggestions. The usual disclaimer applies. †Norges Bank, Monetary Policy Department, Bankplassen 2, 0151 Oslo, Norway, [email protected] ‡Norges Bank, Monetary Policy Department, Bankplassen 2, 0151 Oslo, Norway, [email protected] Contents 1 Introduction 1 2 Norges Bank’s policy model NEMO 1 3 Break points in NEMO 2 3.1 The solution technique ............................. 3 3.2 A change in the inflation target ........................ 3 3.3 A change in the steady-state oil price ..................... 4 4 A practical illustration of the importance of break points 6 5 Estimation of break points 10 6 Concluding remarks 12 Appendices 14 A Algorithm for handling break points in DSGE models 14 A.1 The solution technique ............................. 14 A.2 Impulse response functions (IRFs) ....................... 15 A.3 Simulating the model .............................. 15 A.4 Filtering and smoothing with break points .................. 15 A.4.1 Kalman filter .............................. 16 A.4.2 Kalman smoother ............................ 17 A.5 Estimating break points ............................ 18 B Non-technical Appendix 19 B.1 A short description of NEMO ......................... 19 B.2 Grouping of shocks ............................... 20 B.3 Difference in shock decompositions ...................... 21 ii 1 Introduction Standard solution methods for linear rational expectations models deal with the case where the parameters of the structural model, such as individual preferences, are constant (Kulish and Pagan,2017). In many circumstances, however, this does not give a satisfactory description of the economy. To accurately model a change in some underlying preference or policy, one would need to change one or more parameters at a specific point in time. Usually, this relates to steady-state parameters which cause permanent changes in the model.1For instance, if the inflation target changes or there is a sudden drop in the expected long-term oil price, this should be accounted for in the model by a shift in one or more parameter values at time t, i.e. we should include structural break points2in the model. Since Norges Bank’s inflation target was changed in March 2018, the Bank has had the ability to include structural break points in their main model for economic and monetary policy analysis, the Norwegian Economy Model (NEMO). As will be explained below, the method has already been used in the Bank’s conduct of monetary policy. We are not aware of other central banks that utilize this procedure in large scale DSGE models on a regular basis. This staff memo documents the theoretical solution technique of break points in NEMO, illustrate its usage through examples and show possible implications of not incorporating structural break points properly. The document is organized as follows: Section 2gives a short introduction to NEMO, whereas section 3discusses the solution technique and challenges that break points can accommodate. We demonstrate the importance of including break points in NEMO through an example in Section 4. Section 5describes a procedure to estimate the magnitude and timing of break points based on Bayesian techniques. Lastly, Section 6concludes. 2 Norges Bank’s policy model NEMO The forecasting and policy analysis system in Norges Bank is organized around NEMO. NEMO is a large-scale DSGE open-economy New Keynesian model for monetary policy analysis and forecasting. The model was launched in 2006 and has continuously been updated and extended along several dimensions. NEMO consists of households, domestic (traditional) firms, an oil sector, a government sector and the monetary authority. In addition, there are separate production sectors for housing and non-housing capital goods as well as a banking sector. All agents have rational, or model-consistent, expectations with respect to all prices and quantities, with households’ house price expectations being an important exception. The central bank conducts optimal monetary policy, i.e. sets the interest rate to minimize a loss function. Alternatively the model can be solved under a Taylor type rule. A schematic illustration of NEMO along with some more explanatory text is placed in Appendix B.1. In 2019, the model was re-estimated and thoroughly documented in Kravik and Mimir (2019). 1This need not be the case, however. One could also have shifts in dynamic parameters that do not affect the steady state. 2In the document, we use the terms (structural) break points, (structural) breaks and parameter shifts interchangeably. 1 3 Break points in NEMO Traditionally, when solving DSGE models, parameters of the model have been assumed to stay constant. Up until recently, that was also the case with NEMO. However, new solution techniques have been developed making it possible to include structural break points without large computational costs.3 The benefits of including structural break points in DSGE policy models such as NEMO, should be obvious. For instance, if data display abrupt and long-lasting changes in particular observable variables, indicating a structural break, a proper way of handling such breaks would be to change one or more structural parameters of the model that can be mapped back to the observable(s) at the time of the break. Another useful case is when structural breaks appear in observed policy targets or regulations that are embedded into the model as parameters, such as the inflation target or bank capital requirements. In most cases, the structural parameters in question also change the steady state of the model (as in the examples given below), but the procedure also makes it possible to alter parameters that only change the dynamics of the model.4The change in parameters after the break makes the model interpret historical data differently, draw other shocks and therefore give different forecasts. In recent history, there have been two episodes in Norway where Norges Bank has decided to include break points in NEMO: •First, on 2 March 2018 Norges Bank’s inflation target was lowered from 2.5 to 2 percent. This induced a corresponding change in the steady-state inflation rate in NEMO that would otherwise be hard to implement without the new procedure.5 •Second, in Monetary Policy Report 1/19 Norges Bank wrote that they “now apply the assumption that the depreciation of the equilibrium exchange rate after the oil price fall was slightly more pronounced than assumed earlier.” This is likely to mean that a permanent decline in the real oil price in NEMO was introduced, which, given the structure of the model, resulted in a weaker steady-state real exchange rate and a lower real wage. In both of these cases, introducing the break points led to shifts in the steady state of the model. However, in the former case, the steady states of real variables remained unchanged. Subsections 3.2 and 3.3 below illustrate the effects of a change in the inflation target and a change in the steady-state real oil price in NEMO, respectively. 3The model parameters used for the examples in Section 3and 4deviate somewhat from the ones in Norges Bank’s MPR framework and in Kravik and Mimir (2019). 4For instance, one can imagine that there are periods when rigidities are higher than “normal” times, due to, say, political turbulence. This could then be mapped back to the model by a change in one or more adjustment cost parameters. 5In NEMO, the new inflation target was gradually introduced as the Bank assumed some lag in expectations formations (see Special Feature: Monetary policy implications of a new inflation target in Norges Bank’s Monetary Policy Report (MPR) 1/18). All MPRs are available at https://www. norges-bank.no/en/topics/Monetary-policy/monetary-policy-report/. 2 3.1 The solution technique Constant parameter DSGE models can be represented in the following form Et[F(Xt+1, Xt, Xt−1, Ut, θ)] = 0,(1) where Fis the set of possibly non-linear equations of the model, Xtis a Q×1vector of endogenous variables, Utis a N×1vector of exogenous variables, and θis the parameter vector of the model. Introducing break points entails that we let the parameters become regime-dependent: Et[F(Xt+1, Xt, Xt−1, Ut, θr)] = 0,(2) where θris the vector of parameters in regime r∈ {1, ..., s}. As long as the structural break points are unanticipated, i.e. the parameter changes are not known or expected by the agents before they occur, solving equation (2) is reduced to finding the solution for each regime separately. In general, where regime rdepends on time t. See Appendix A.1 for details. The procedure outlined above gives a simple and flexible way of applying break-points to a model, with the only computational cost being to solve the model once per regime. These properties of the technique are important because of the large size of NEMO and the heavy reliance on the model in the MPR process. Note that this approach is different from what is often referred to as regime-switching DSGE models (RS-DSGE models), in which the regime in period tis (either endogenously or exogenously) determined by a Markov process and the agents have the capability to form expectations over the regimes.6Also within the RS-DSGE framework one can have absorbing regimes by proper calibration of the Markov chain, but in general, this procedure is computationally more demanding.7 Kulish and Pagan (2017) show how a similar method to the one used in NEMO can be extended to the case where the structural changes are foreseen. Implementing this feature in NEMO is left for future work. 3.2 A change in the inflation target Altering structural parameters can be interpreted as permanent shocks. When a structural break is introduced, potentially all endogenous variables will transition from the previous to the new steady state (similar to impulses responses from a temporary shock). See Appendix A.2 for details. Figure 1shows impulse responses from a sudden (and unanticipated) negative shock of 0.5 percentage points to the (annualized) inflation target in NEMO. Variables are shown in percent deviation from the original steady state. Flow variables are in fixed prices on a quarterly basis. The dotted lines indicate the new steady state. The model is solved under optimal policy. 6Strictly speaking, both the Markov switching framework and the break point framework deal with switching regimes. However, the term regime-switching model is usually applied to the former case. 7For a number of years there has been a growing literature on how to deal with structural breaks in RSDSGE models, and technically, implementing regime switching is now relatively easy. For instance, Maih (2015) has developed a flexible and easy-to-use object-oriented toolbox, named RISE, that is able to solve RS-DSGE models, allowing for endogenous transition probabilities and for agents to react to anticipated events (freely available). See reference for a comprehensive review of the literature on Markov switching models up until 2015. 3 Although agents in the model have rational expectations (except with respect to house prices), the change in inflation target leads to a relatively slow transition to the new steady state due to rigidities operating in the model. The new inflation level is reached after about 20 quarters. The positive inflation gap that immediately opens causes the central bank to hike the policy rate which increases the real policy rate by about 20 basis points (at maximum) on an annual basis. The contractionary monetary policy is transmitted to the real economy through the banking sector via a gradual pass-through from the policy rate to the household and corporate lending rates. This suppresses demand components, such as output, investment and consumption. The real wage level also falls. The rise in the real policy rate contributes to a stronger real exchange rate, generating a reduction in exports. Note that a change in the inflation target causes a trade-off as it opens up a positive inflation gap and a negative output gap. As a result, the monetary authority chooses a smooth transition to the new inflation target. The real effects of a change in the inflation rate in the long-run are negligible. Inflation (in annul. ppts.) 5 10 15 20 25 30 35 40 0 0 Policy rate (in annul. ppts.) 5 10 15 20 25 30 35 40 0 0 Real policy rate (in annul. ppts.) 5 10 15 20 25 30 35 40 0 0.1 0.2 0 0.1 0.2 Investment 5 10 15 20 25 30 35 40 0 0 Real wage 5 10 15 20 25 30 35 40 0 0 Real exchange rate 5 10 15 20 25 30 35 40 0 0 Mainland output 5 10 15 20 25 30 35 40 0 0 Consumption 5 10 15 20 25 30 35 40 0 0 Mainland export, excl. oil supply 5 10 15 20 25 30 35 40 0 0 Figure 1: A drop in the inflation target in NEMO. Flow variables are in fixed prices on quarterly terms in percent deviation from the original steady state. The real wage, real exchange rate and real policy rate are deflated by the inflation rate. The dotted lines indicate the new steady states. 3.3 A change in the steady-state oil price Oil and gas production have traditionally made up about 45 to 50 percent of total export value and between 20 to 30 percent of total GDP in Norway since 2000 (Statistics Norway, 2016). Permanent changes in the oil price can therefore potentially have large effects the long-term growth path and real wages in Norway. 4 magnitude, we choose a normal prior with mean of no break, and standard deviation of 0.1. For the timing of the break, we use a uniform discrete prior on the interval -4 to 4. To evaluate the log-likelihood given the parameters we use the Kalman filter described in Appendix A.4. For more details on the estimation procedure, see Appendix A.5. We estimate the model over the same simulated sample as in the previous section. The estimation results are provided in Table 1. We can see the estimation is able to detect the timing and magnitude of the decline in the oil price quite well: Results indicate the timing of the break at period 0 and a decline in the steady-state oil price of 9.8 percent. Table 1: Estimation results Parameter Prior distribution Prior mean Prior st. dev. Posterior mode Magnitude of break Normal 1 0.1 0.902 Parameter Prior distribution Prior mean Prior bounds Posterior mode Timing of break Discrete Uniform 0 [-4,4] 0 In Figure 7we plot the curvatures of the log-posterior distributions, log-likelihood and log-prior distributions around the prior means. As we see from the figure, the prior distributions do not steer the estimation to the conclusion, as the shape of the log-posterior distributions and log-likelihoods are almost identical. Based on this, we can conclude that we are able to identify the decline in the oil price well. Curvature of oil price decline 0.8 0.9 1 1.1 1.2 0 10000 Curvature of timing of oil price decline 024 0 5000 10000 0 Likelihood Posterior Prior Likelihood Posterior Prior Figure 7: The blue lines (hidden behind the yellow lines) indicate the curvatures of the loglikelihoods, the yellow lines are the curvatures of the log-posterior distributions,awhereas the purple lines are the log-prior distributions of the magnitude of the oil price decline and timing of the oil price decline, respectively. The figures are centered around the prior means. The orange dashed lines indicate the posterior modes. The true value is 0.9 for the decline in the oil price, while it is 0 for the timing of the decline in the oil price. aAs defined by the last term in equation (33) in Appendix A.5. Although the estimation routine was successful, a weakness of this exercise is that the data are simulated from the model, and that the sample is quite long. As noted by Kulish and Pagan (2017), in practice, it is usually the magnitude of changes in the properties of observable variables that is used to help define subsamples for which a time-invariant structure is assumed to be valid. This is also the procedure followed by Norges Bank in the examples mentioned in Section 3. Investigating the estimation procedures on actual data is left for future research. 11 6 Concluding remarks Standard solution methods for rational expectations models deal with the case where the parameters of the model are time-invariant. However, to accurately model a change in some underlying preference or policy, one would need to change one or more parameters at a specific point in time. Since Norges Bank’s inflation target was changed in March 2018, Norges Bank has had the ability to include simple structural break points in their main model for economic and monetary policy analysis, the Norwegian Economy Model (NEMO). This property was introduced to enable the model to answer new policy-relevant questions, such as the effect of changes in the inflation target and the effect of a sudden drop in the expected long-term oil price. This staff memo has documented the theoretical solution technique of break points, illustrated its usage through examples and showed possible implications of not incorporating structural break points properly. Additionally, we have presented a procedure for estimating break points. Our results indicate that including structural shifts is important when interpreting data. Neglecting structural shifts can lead to wrong interpretations of history, which, potentially, could also affect forecast performance. 12 References Bergholt, D., Larsen, V. H. and Seneca, M. (2019) Business cycles in an oil economy, Journal of International Money and Finance,96, 283–303. Canova, F. and Ferroni, F. (2011) Multiple filtering devices for the estimation of cyclical DSGE models, Quantitative Economics,2, 73–98. Debortoli, D., Maih, J. and Nunes, R. (2010) Loose commitment in medium-scale macroeconomic models: Theory and an application, Working Paper 2010/25, Norges Bank. Hamilton, J. and Press, P. U. (1994) Time Series Analysis, Princeton University Press. Karaboga, D., Gorkemli, B., Ozturk, C. and Karaboga, N. (2012) A comprehensive survey: Artificial bee colony (abc) algorithm and applications, Artificial Intelligence Review,42. Klein, P. (2000) Using the generalized Shur form to solve a multivariate linear rational expectation model, Journal of Economic Dynamics and Control,24, 1405–1423. Koopman, S. and Durbin, J. (1998) Fast Filtering and Smoothing for Multivariate State Space Models, Tech. rep. Kravik, E. M. and Mimir, Y. (2019) Navigating with NEMO, Staff Memo 5, Norges Bank. Kravik, E. M., Mimir, Y. and Paulsen, K. S. (n.d.) A complete documentation of Norges Bank’s policy model NEMO, Tech. rep., Norges Bank, http://www.norges-bank.no/ en/Monetary-policy/Models-for-monetary-policy-analysis-and-forecasting/ NEMO/, continuously updated. Kulish, M. and Pagan, A. (2017) Estimation and solution of models with expectations and structural changes, Journal of Applied Econometrics,32, 255–274. Maih, J. (2015) Efficient perturbation methods for solving regime-switching DSGE models, Working Paper 2015/01, Norges Bank. Schmitt-Grohé, S. and Uribe, M. (2003) Closing small open economy models, Journal of International Economics,61, 163–185. Statistics Norway (2016) Dette er Norge 2016: Hva tallene forteller, Reports, Statistics Norway (in Norwegian only). 13 Appendices A Algorithm for handling break points in DSGE models A.1 The solution technique Dynamic stochastic general equilibrium (DSGE) models can be put on the form Et[F(Xt+1, Xt, Xt−1, Ut, θS(t))] = 0,(3) where Fis a function that represents the set of possibly non-linear equations of the model, Xtare the endogenous variables. Utare the exogenous variables, which cannot appear with any order of lead or lag, with size N. Let the number of equations be given by M, which must also be the number of endogenous variables (=Q).11 θS(t)is the parameter vector of the model that may change unexpectedly over time. In what follows we assume that θS(t)∈Rp, and that there are countable number of different regimes, i.e. θS(t)∈ {θ1, ..., θs} for some finite s∈N+, and that the function S(t)is a indicator function for which regime we are in at the time t.p∈N+will be the number of parameters of the model. To be able to solve the non-linear system in equation (3) we need to do an approximation. The first step is to solve the multivariate non-linear system F(Xss r, Xss r, Xss r,0, θr) = 0 ∀r∈[1, s],(4) where the found solution Xss ris the steady state in regime r. Then we do a 1st order Taylor expansion around the steady state in each regime to get A+ θr(Xt+1 −Xss r) + A0 θr(Xt−Xss r) + A− θr(Xt−1−Xss r) + BθrUt= 0.(5) In the case of optimal monetary policy we optimize a loss function (where Ware the weights in the loss function) ∞ X t=0 βtX0 tWXt,(6) s.t. equations in (5). In the monetary policy rule case the rule is already part of the equations in (5). We are looking for a solution on the form Xt=Xss S(t)+AS(t)(Xt−1−Xss S(t)) + CS(t)Ut,(7) As noted in section 3.1.1 of Kulish and Pagan (2017) we can then find the solution to the problem by finding the solution for each regime separately. Which means that we can use one of the standard solution methods suggested in the literature. We use the generalized Shur form suggested by Klein (2000) when monetary policy is specified using a rule, and the loose commitment algorithm suggested by Debortoli et al. (2010) if monetary policy is specified using a loss function. 11Except if the model is solved with optimal monetary policy. In this case M=Q−1. 14 A.2 Impulse response functions (IRFs) For break point models the break points are set to precise dates, but since IRFs do not relate to any date, we need to use another way of defining the regimes. In the case where we have added Bbreak points we have R=B+ 1 regimes. In the case of B= 1 we have the first regime is going from the beginning of time until, but not including the given break period, and the second regime is going from the break period to the end of all time. By classifying the regimes in this way we can produce IRFs by condition on the regimes for all periods of the IRFs, call this path of regimes ρ(t)∀t∈ {0, ..., T }, where Tis the total number of periods of the IRF. ρ(0) is the regime we start out from. An IRF for the structural shock jthat hits at period 1 is then given by E"(∂Xt−Xss ρ(t)) ∂Uj,1#=Aρ(t)E"∂(Xt−1−Xss ρ(t)) ∂Uj,1#∀t∈ {1, ..., T },(8) where Eh∂(X0−Xss ρ(1)) ∂Uj,1i=Cρ(1)ej,1+Aρ(1)(Xss ρ(0) −Xss ρ(1)).ej,1is a vector of zeros except at the element jwhere it is 1, and Xss ρ(0) is the starting values of the endogenous variables, e.g. the steady state in the regime we start out from. Equation (8) will then give you the IRF of the variables as deviation from the steady state. To get the IRF in levels we need to add the steady state at each period (Xss ρ(t)) to Eh(∂Xt−Xss ρ(t)) ∂Uj,0i. In the special case that ρt=r∀t∈ {1, ..., T}we get the definition of IRF of a shock in a specific regime r. We can also specify a IRF to a change from one regime rto regime s. It is given by EXt−Xss ρ(t)=Aρ(t)EXt−1−Xss ρ(t)∀t∈ {1, ..., T},(9) where X0=Xss ρ(0), where ρ(0) = rand ρ(t) = s∀t > 0. A.3 Simulating the model To simulate a model with unexpected structural break points one can use the solution found in equation (7) to get Yt+h=Xss S(t+h)+AS(t+h)(Yt−1+h−Xss S(t+h)) + CS(t+h)Ut+h.(10) In equation (10) we first remove the steady-state at time t+hfrom the initial value Yt−1+h, before we make a simulation of the deviation from the steady-state by the full second term. Then the contribution from the simulated exogenous shocks may be added, before we re-add the steady-state values at time t+hagain. To simulate a series with length H, one iterates equation (10)Hperiods, and Ut+h∼N(0, I). A.4 Filtering and smoothing with break points We can rewrite the model in equation (7) into a state-space representation. The measurement equation can be posted as Yt=HXt+vt.(11) Ytare the observable variables with size O×1,His the observation matrix with size O×M, and vtare the measurement errors with size O×1. The measurement error is 15 assumed to be normally distributed with covariance matrix R, where Rhas size O×O,12 i.e. vt∼N(0, R).(12) The state equation linking the current state of the state variables with its own lags and some exogenous disturbances is given by (7). The disturbances (Ut) is assumed to be normally distributed with covariance matrix I,13 i.e. Ut∼N(0, I).(13) See Hamilton and Press (1994), Section 13.1, for a more thorough description of the state-space representation. A.4.1 Kalman filter The piecewise linear Kalman filter can be used to get estimates of state variables, or the unobservable variables, given the observable variables and the parameter values of the model. This filter assumes that the model is stationary in each regime. Let us start out with some definitions. Xt|t−1=Et−1[Xt]is the expectation of Xt given information on the observed variables up until time t−1, while Xt|t=Et[Xt]is the expectation of Xtgiven information on the observed variables up until time t. First we can use equation (11) to predict Ytusing Xt|t−1 Yt|t−1=HXt|t−1,(14) as Et−1[vt]=0. To get a measure of the forecast error variance we can use equations (11) and (14) to get Ft=E[(Yt−Yt|t−1)(Yt−Yt|t−1)0] =E[H(Xt−Xt|t−1)(Xt−Xt|t−1)0H0] + E[vtv0 t] =HPt|t−1H0+R, (15) where Pt|t−1is the variance in the error when forecasting Xtgiven information on the observed variables up until time t−1. We need Ftas we want to update the projection of Xt|t−1given the new information on Yt Xt|t=Xt|t−1+E[(Xt−Xt|t−1)(Yt−Yt|t−1)0]F−1 t(Yt−Yt|t−1) =Xt|t−1+Pt|t−1H0F−1 t(Yt−HXt|t−1),(16) where we in line 2 have used equation (14) and E[(Xt−Xt|t−1)(Yt−Yt|t−1)0] = E[(Xt−Xt|t−1)(H(Xt−Xt|t−1) + vt)0] =Pt|t−1H0,(17) The associated variance of Xt|tis 12It is assumed that the measurement error is uncorrelated across time. In the examples in Section 4, we assume R= 0. 13It is assumed that the exogenous disturbances is uncorrelated across time. 16 Pt|t=E[(Xt−Xt|t)(Xt−Xt|t)0] =Pt|t−1−Pt|t−1H0F−1 tHPt|t−1.(18) But we are interested in Xt+1|tand Pt+1|t. These we can find by first noting that Xt+1|t=Xss S(t+1) +AS(t+1)(Xt|t−Xss S(t+1)).(19) By substituting equation (16) into equation (19) we get Xt+1|t=Xss S(t+1) +AS(t+1)(Xt|t−1−Xss S(t+1)) + Ktνt,(20) where we have defined νt=Yt−HXt|t−1and Kt=AS(t+1)Pt|t−1H0F−1 t. With the associated variance Pt+1|t=AS(t+1)Pt|tA0 S(t+1) +CS(t+1)CS(t+1) =AS(t+1)(Pt|t−1−Pt|t−1H0F−1 tHPt|t−1)A0 S(t+1) +CS(t+1)C0 S(t+1) =AS(t+1)Pt|t−1(A0 S(t+1) −H0K0 t) + CS(t+1)C0 S(t+1). (21) The starting values of the filter is set to the unconditional mean of X1and P1 X1|0=E[X1] = Xss 1(22) vec(P1|0) = E[X1X0 1]=(IM2−A1⊗A1)−1vec(C1C0 1).(23) To evaluate the log likelihood we can at each step of the filtering calculate `t=−log(|Ft|)−ν0 tF−1 tνt.(24) Which means that the full log likelihood over T periods can be calculated as L=−T·O·log(2π) 2+PT t=1 `t 2.(25) A.4.2 Kalman smoother In contrast to the piecewise linear Kalman filter the piecewise linear Kalman smoother uses all the information in the observable variables to estimate the unobservable variables. The first part of the smoother is to run through the filter. Then by a backward recursion on the following equation you can get the smoothed estimates Xt−1|T=Xt−1|t−1+Jt−1(Xt|T−Xt|t−1)for t=T, . . . , 2(26) Jt−1=Pt−1|t−1A0 tP−1 t|t−1.(27) See Hamilton and Press (1994), Section 13.6, for a more thorough description of the Kalman smoother and its properties. The algorithm implemented in the code used in this paper follows the smoothing steps of Koopman and Durbin (1998): Rt=A0 S(t)Rt+1 +H0F−1 tνt−H0K0 tRt+1,(28) 17 Xt|T=Xt|t−1+Pt|t−1Rt,(29) where RT+1 = 0. Smoothed estimate of Utcan be found using ut|T=C−1 S(t)(Xt|T−Xss S(t)−AS(t)(Xt−1|T−Xss S(t))).(30) for t > 1, while for t= 1 we get u1|T=C−1 S(t)(X1|T−X1|0).(31) A.5 Estimating break points We are interested in estimating the parameters θi∀iand potentially the timing of the structural breaks, i.e. the S(t)function. When estimating S(t)we assume that the number of structural breaks sis known prior to estimation. Let the timing of the s breaks be collected into the vector θb, then we can collect all parameters of the model as θ= [θ1,· · · , θs, θb].θwill have size k= (p+ 1)s.14 As is normal in this literature, we first formulate a set of marginal independent priors p(θ|M) = p(θ1)× · · · × p(θk).(32) A Bayesian approach constitute of estimating the parameters θby maximization of the posterior distribution given by p(θ|Y, M) = L(Y|θ, M)×p(θ|M) p(Y|M)∝ L(Y|θ, M)×p(θ|M).(33) As the prior and posterior distributions of the timing of break points are discrete we cannot use a derivative based maximization methods to estimate the model. Instead we use the artificial bee colony (ABC) algorithm. See for example the survey of Karaboga et al. (2012) for an introduction to this method. 14Estimation can of course be limited to a subset of θif wanted. 18 B Non-technical Appendix B.1 A short description of NEMO NEMO consists of households, intermediate goods and final goods producing firms, an oil sector, a government sector and the monetary authority. In addition, there are separate production sectors for housing and non-housing capital goods as well as a banking sector. All agents have rational, or model-consistent, expectations with respect to all prices and quantities, with households’ house price expectations being an important exception. The model is thoroughly documented in Kravik and Mimir (2019). A technical documentation of all derivations, first-order conditions, the full steady-state solution and the stationarization of the model can be found in Kravik et al. (n.d.).15 Government Final goods producers Housing investment Households Banking sector Capital producer Interm. goods producers Oil supply sector Foreign oil extractors Rig producers Oil extractors Oil fund Foreign sector Risk premium G IH H BhD LI LO KI KO Be IC MO∗ IOF FO M∗ YO B∗ B∗BF M Q QO C Figure 8: A bird’s eye view of NEMO Figure 8provides a schematic illustration of the model and displays how the different sectors and agents are linked to each other. The numeraire good of the model, the final good, is shown near the top of the figure. This is produced by combining inputs from the 15Kravik et al. (n.d.) is a live document. See the reference list for a link to the latest version. 19 domestic firms (Q), labeled intermediate goods producers in the figure, and imports (M). The final goods are converted into household consumption (C), corporate investment (IC), housing investment (IH), government expenditures (G) and used as inputs in the oil sector (QO). The intermediate goods producers employ labor supplied by households (LI), rent capital from entrepreneurs (KI) and sell their goods to the final goods producers (Q) and as export (M∗). The oil sector uses labor (LO), capital (KO) and final goods (QO) to produce oil supply goods which are exported (MO∗) or sold to the domestic rig producers (IOF ). The rig producers invest in oil rigs (FO) in order to extract oil (YO) that in turn is exported in full. The revenues are invested in the Government Pension Fund Global (GPFG), named “Oil fund” in Figure 8. Households consume (C), work in the intermediate goods sector (LI) and in the oil sector (LO), buy housing services (H), and interact with banks through borrowing (Bh) and savings through deposits (D). The banking sector lends to households (Bh) and entrepreneurs (Be), and is funded through deposits (D), foreign borrowing (B∗), and equity (KB). An uncovered interest parity relationship (UIP) together with the country’s net foreign debt position (private borrowing, B∗, minus government claims on foreigners, BF) tie down the debt-elastic risk premium to ensure stationarity.16 B.2 Grouping of shocks The shocks in the historical shock decompositions in Section 4are grouped according to Table 2. Table 2: Categorization of estimated structural shocks Domestic demand Domestic supply Foreign Consumption preference Temporary productivity Foreign marg. costs Housing preference Firm inv. adj. costs Global demand Government spending Housing inv. adj. costs Export demand pref. Import demand Price markup Foreign interest rate Wage markup Foreign inflation Trading partners’ output Exchange rate Banking sector Oil sector External risk premium Money market risk premium Real oil price Household LTV ratio Oil investment Monetary policy Entrepreneur LTV ratio Oil production abroad Inflation target Markup of mortgage loan rate Markup of business loan rate Note: The exchange rate shock is an external risk premium shock in the UIP condition. The monetary policy shock under the optimal policy setup is implemented as a shock to the inflation target, which is equivalent to unanticipated deviations of the policy rate from the optimal monetary policy prescription. 16This is one of the standard ways of solving the unit problem inherent in small open economy models with incomplete markets (see Schmitt-Grohé and Uribe (2003)). 20