Estimating output gap: a beauty contest approach
Abstract
Over the last decades, the estimation of the slack in the economy has become an essential piece of analysis for policymakers, both on the monetary policy and the fiscal policy front. Output gap estimation techniques have flourished accordingly, although there is no consensus on a bestperforming methodology, as the selection criteria often imply important tradeoffs. This paper presents a novel approach putting the focus on the specification of the model rather than on a prior selection of the methodology itself. Ideally, an agreeable method should achieve three necessary conditions: economic soundness, statistical goodness and transparency. On top of this, consistency with the business cycle narrative, as often implemented by policymakers, is also a critical condition. In practice, fulfilling these conditions can prove to be challenging. The main issues in practice are related to the specification of the model, the selection of the relevant variables, the stability and uncertainty of the estimates and its use on a realtime basis. This paper presents a methodological approach based on a structural multivariate time series model and Kalman filtering. The method fulfils the necessary criteria and allows for enough flexibility in order to get a countryspecific approximation to the sufficient criterion as it could accommodate specific cycles (financial, external, investment, fiscal, etc.). The method is put to the test with an illustration for the Spanish economy, assessing its merits as well as its limitations.
Keywords
Spanish economy Output gap Kalman filter Business cycleJEL Classification
C11 C32 C51 C53 C611 Introduction
Policymakers strive to understand the dynamics of the business cycle and pinpoint its specific location as it decisively determines the outcome of policy decisions. The slack or output gap, defined as the amount of unemployed resources (i.e. the distance to potential output) is, however, not observable and surrounded by considerable uncertainty.
The literature has developed a myriad of estimation techniques over the last decades, ranging from datadriven univariate filters to structural general equilibrium models.^{1} The horse race in search of an optimal output gap estimation methodology seems far from settled. On the one hand, the uncertainty surrounding the output gap estimates has proven a challenging task, leading to unreliable estimates in real time, which happens to be the policyrelevant time frame. On the other hand, confronting output gap estimates with optimality criteria (both statistical and economic ones) has generally led to inconclusive results, as the former might be illdefined or even incompatible and thus a selection algorithm becomes necessary.
The selection criteria should aim at providing a welldefined metric or comparable benchmark for different estimates. In practice, they can generally be split into three dimensions. First, statistical goodness (SG) referring to elements such as minimizing the endpoint problem or providing information on the precision of the estimates. Second, economic soundness (ES) implying exante consistency between selected stylized facts and the method’s underlying assumptions. And third, transparency (TR) requirements as seen from a userspecific perspective, reflecting accountability elements such as likelihood of replication or data needs.
This paper builds upon existing research on output gap measurement techniques and presents an approach for the selection of an output gap estimate that pivots around a multivariate unobserved components (MUC) Kalman filter estimation. Multivariate filters and the unobserved components multivariate Kalman filter technique represent a good compromise between the necessary criteria, falling within the optimality area in Fig. 1. First, the use of a multivariate framework allows for the consideration of additional economic relationships (Okun's Law, Phillips Curve, etc.) going beyond univariate filters while at the same time imposing lighter economic priors than fully structural models and thus sticking more closely to the data. Second, the statistical properties of multivariate techniques clearly outperform other methods such as the production function approach, allowing for example for an integrated estimation of uncertainty. Third, multivariate approaches are generally not dataintensive and thus easily replicable and largely transparent, being more parsimonious than fullyfledged economic models.^{2}
The focus for the selection of a specific output gap estimate is diverted from the traditional model horse race, which focuses on the comparison between different methodologies along the three necessary criteria (ES, SG and TR). Instead, the final estimate is derived from a beauty contest between candidate variables in a MUC framework. Different specifications of the model are tested by combining GDP with potential candidate variables sharing relevant information about the business cycle. The latter can include domestic (capacity utilization, unemployment), openeconomy (current account, exchange rate), financial (credit to nonfinancial corporations) and price (GDP deflator, CPI, house prices) candidates. The selected approach allows for countryspecific cycle definitions, generalizing the work in Borio et al. (2017) and Alberola et al. (2013).
The paper is structured as follows; Sect. 2 details the estimation methodology, Sect. 3 specifies the necessary and sufficient criteria and develops the selection algorithm, Sect. 4 present an application for Spain as a case study and Sect. 5 concludes. Finally, two appendices complete this contribution, the first one devoted to the implementation of the Kalman filter and, the second one, giving details on the statistical features of the selected output gap estimate for Spain.
2 Econometric methodology
This section develops the econometric approach used to estimate the output gap as well as the associated cyclical (or transitory) components. This section has two parts. The first one is devoted to the presentation of the multivariate model used to estimate the output gap and the second one to its estimation by means of the Kalman filter.
The econometric approach is based on the wellknown Structural Time Series (STS) representation of a time series vector, see Clark (1987), Harvey (1989), Kuttner (1994), Kitagawa and Gersch (1996), Kim and Nelson (1999) and Durbin and Koopman (2001), among others. This method is rather general and flexible albeit keeping the number of parameters tightly controlled, in contrast with other econometric approaches (e.g. Vector of autoregressions, VAR).
2.1 The structural multivariate time series model
The structural decomposition provides an efficient way to estimate the output gap or, more generally, to decompose an observed time series as the sum of an arbitrary number of unobserved elements.
Note that, in general, the structural model imposes an I(2) representation for the trend although, depending on the values of the variances of the shocks, this representation can collapse into an I(1) trend (with or without deterministic drift) or a linear trend plus noise. In this way, the model provides a flexible and parsimonious way to represent different nonstationary dynamics.^{3}
In the remaining of the paper complete orthogonality among the shocks is assumed.
The model for the GDP, see Eqs. (1)–(4), can be extended just by including additional variables whose stationary component is related to the output gap. This extension allows for the introduction of relevant macroeconomic stylized facts (as the Okun’s Law, the Phillips Curve, etc.).
In this way, their observed values, properly filtered, provide additional information to estimate the output gap. The trend of the additional variables can be I(2) or I(1). For the sake of simplicity, let us consider two additional variables, one with an I(2) trend and the other with an I(1) trend.
2.2 Kalman filtering
Given some initial conditions for the state vector S_{0} and assuming that the vector ϴ is known, the Kalman filter can be used to estimate the state vector and its corresponding standard error. In practice, the vector ϴ is not known and must be estimated from the sample. Fortunately, the state space format and the Kalman filter provide a feasible way to evaluate the likelihood function and, using numerical methods, to maximize it.

Initialization 1 Set initial parameters: ϴ_{0}.

Initialization 2 Set initial conditions: S_{00}. Initial conditions for the state vector are provided using a diffuse prior centered on zero with an arbitrarily large VCV matrix.

Likelihood computation Conditioned on the initial parameters and the initial conditions, we run the Kalman filter to compute the likelihood, see “Appendix A” for the detailed implementation of the Kalman filter algorithm.

Likelihood maximization The maximum likelihood estimation (MLE) is implemented numerically via the fminunc^{4} function from the Matlab optimization toolbox. The definition of the objective function incorporates the constraints that ensure the nonnegativity of the variances and the stationary nature of the AR(2) parameters.

Reinitialization The use of diffuse initial conditions to run the Kalman filtering is a simple device to start its algorithm but may generate some sensitivity in the estimates of the state vector. To desensitize these estimates, we generate backcasts^{5} (e.g. forecasts of observations prior to the first observation). This process of backcasting is done just by projecting forward the model using the reversed time series. In this way, we obtain a new set of initial conditions S_{01} that exerts a limited influence on the estimation of the state vector as derived by means of the Kalman filter.

Onesided (concurrent) estimates of the state vector The onesided (or concurrent) estimates of the state vector are obtained running recursively the Kalman filter from t = 1 to t = T (forward in time). This estimate considers only the information available from t = 1 to t = h to estimate the state vector at time t = h and is very useful to analyze the state of the system on a realtime basis. See “Appendix A” for a detailed exposition.

Twosided (historical, smoothed) estimates of the state vector In addition, the twosided (or historical) estimates of the state vector are obtained running recursively the Kalman filter from t = T to t = 1 (backward in time), using as initial conditions the terminal concurrent estimates obtained in the previous step. This process considers all the information available from t = 1 to t = T to estimate the state vector at any time t = h, 1 ≤ h≤T. The smoothing algorithm is formalized in “Appendix A”.
From an econometric view, onesided and twosided estimates play a complementary role. The first one serves as the starting point for the second and provides a benchmark to quantify the additional precision that the full sample introduces. Note that twosided estimates are more precise because they incorporate all the available information from t = 1 up to time t = T to estimate the state vector in any intermediate point and, due to their symmetric nature. Note that this symmetry is due to the fact that the filter runs backward from estimates derived forward. In this way, twosided filtering does not introduce any form of phaseshift in the estimates.
However, this estimate is not useful for realtime analysis since it incorporates information not available a t = h to evaluate the state of the system at that time and hence introduces some form of hindsight bias. This is particularly important when dealing with output gap estimation because its main use is related to the assessment of the fiscal policy stance. In practice, fiscal policy at time t is primarily determined using only information available up to time t^{6} and this explains the preeminence that we will attach to onesided estimates in the empirical application.
Of course, this preeminence does not imply that twosided estimates are irrelevant. Quite the contrary, they serve to produce useful measures of uncertainty and to gauge the impact of the full sample on the estimates of the output gap, especially around the turning points.
3 Selection criteria
As mentioned before, the potential output of the economy cannot be measured directly, consequently there is no observable target or benchmark for comparison. This makes it difficult to evaluate alternative specifications.^{7}
To operationalize the optimality requirements specified previously, this section defines a set of criteria covering the relevant dimensions against which to gauge the different estimates. These criteria are split into two categories. First, the statisticalbased ones define the necessary conditions. Second, the more economically and policyoriented ones, underline the sufficient conditions.

Criterion 1 Statistical significance of the coefficients, focusing on the loadings of the observables on the cycle;

Criterion 2 Average relative revision, defined as the average distance between onesided and twosided estimates, relative to the maximum amplitude of the output gap estimate;

Criterion 3 Average relative uncertainty surrounding the cycle estimates, as the average standard error relative to the maximum amplitude.
As we have already noted, output gap estimation is a (fiscal) policyoriented exercise that is implemented through econometric procedures. In this way, for good and for bad, the results must be considered taking into account its usefulness for policymakers and fiscal monitoring. Revisions play an important role in the assessment of the results. From a statistical view, revisions are the price that we pay to have the most reliable and updated output gap estimates. On the other hand, policymakers and supervisors tend to view revisions as a nuisance that complicates decision making and the implementation of fiscal rules.
For the same reasons, being other things equal, the more precise the estimates (i.e. the lower its standard error), the better because in this way the policy assessment can be made in a more precise way. These are the rationale for criteria 2 and 3.

Criterion 4 Economic soundness, meaning that some key macroeconomic relationships could be captured by variables if included in the model (e.g. Okun’s Law, Phillips Curve, etc.);

Criterion 5 Amplitude and profile alignment with consensus figures (range given by a panel of official institutions) and in agreement with commonly accepted business cycle chronology (e.g. ECRI dating). The quantification of the profile alignment can be made by means of the crosscorrelation function and different measures of conformity, e.g. Harding and Pagan (2006)^{8};

Criterion 6 Stability of the onesided cycle estimate, as this would mimic the practitioner’s need for updated estimates as new data is added in real time.^{9} Stability can be measured using the revisions of the onesided estimates.
Criterion 5 deserves an additional explanation. Since output gap measurement is made for policymaking and policy assessment, agreement with the profile of official estimates is a plus when comparing among alternative estimates. Of course, synchronicity (i.e., turning point coincidence) is more important than an exact match between the magnitude of the output gap estimates.
4 Let the data speak: an application to Spain
With hindsight, this vision was clearly misguided, By the early 2000s, Spain was already accumulating large imbalances and heating pressures were present although not visible in headline inflation figures. For example, as can be seen in panels b in Fig. 2, the current account was leaking. Extending the concept of structural unemployment from the NAIRU to include a balanced external sector^{10} already reveals a downward bias in the former as it did not take into account all the relevant dimensions. Why stop there? Other variables might have also been relevant in defining and identifying the Spanish cycle, such as investment in construction, which was soaring (see Fig. 2c) together with prices in nonfinancial assets (mainly dwellings).
By letting the beauty contest between the different candidate variables take place, the methodology developed in previous sections provides an efficient algorithm for variable selection. Previous attempts at describing the Spanish cycle with a similar methodology can be found in Doménech and Gómez (2006), Doménech et al. (2007) and Estrada et al. (2004). In particular, our approach is affine to the first one.^{11}
4.1 Data set and data processing
Data set
Variable  Unit  Source 

GDP  Volume index (base 2010 = 100)  INE 
Internal demand  
Investment, construction  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  INE 
Investment, equipment  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  INE 
Productive capacity utilization  %  MINETUR 
External sector  
Real effective exchange rate  Index 1999 I = 100  Bank of Spain 
Current account balance  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  Bank of Spain 
Gross national savings  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  INE 
Prices  
CPI, general  (i) Price index (base 2011 = 100); (ii) growth rate, % change  INE 
GDP deflator  (i) Price index (base 2011 = 100); (ii) growth rate, % change  INE 
Compensation per employee  Euros per employee  INE 
Housing prices  Euros per square meter  MFOM 
Labour market  
Unemployment rate  %  
Employment, fulltime equivalent  Thousands  INE 
Hours worked per employee  Units  INE 
Compensation of employees  (i) Volume index (base 2010 = 100); (ii) M€  INE 
Financial and monetary sector  
Credit to nonfinancial corporations  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  Bank of Spain 
Credit to households  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  Bank of Spain 
Broad money (M3 aggregate)  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  Bank of Spain 
Narrow money (M1 aggregate)  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  Bank of Spain 
Fiscal variables  
Public debt, excessive deficit procedure  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  Bank of Spain 
Net lending (+), net borrowing (−): general government  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  INE 
Taxes on production and imports  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  INE 
Taxes on income and wealth  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  INE 
Social contributions  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  INE 
Unemployment benefits  (i) Volume index (base 2010 = 100); (ii) M€; (iii) % GDP  MEYSS 
In relation to data processing, all the variables must be corrected from seasonal and calendar effects to get a signal free of possible distortive elements that helps to calculate more accurately the cyclical component of the economy. In the case of the series from the Quarterly National Accounts, they are already published corrected of such effects. For the remaining time series, Tramo–Seats is used (Caporello and Maravall 2004).^{12}
All series have been extended and/or completed until the first quarter of 1980, considering their specificities (sources, concepts, different statistical bases, mixed frequencies, etc.). The sample ends in 2016Q4.
Overall, the necessary processing could be summarized by backward linking retropolation and temporal disaggregation when needed.^{13} Moreover, additional benchmarking techniques are implemented whenever the seasonal adjustment process breaks the temporal consistency with respect to the annual reference.
Finally, there are three main issues to set before performing the estimation of the different combinations: (a) the cyclical behavior of the selected variables, accompanying the GDP; (b) their order of integration; and (c) unit specification.
4.2 Selection results
The selection of the relevant variables follows a reductionist approach according to the criteria specified above, starting with the necessary conditions. In this context, reductionist means that the complete list of potential variables is pruned through a specification process to derive a shorter list that will form the basis for the final econometric model. Every variable is modelled in a bivariate framework together with real GDP.
Selected variables according to criteria 1–5.
Source of data: author’s estimations
Variable  Transformation  Criteria 1  Criteria 2  Criteria 3  Criteria 4  Criteria 5 

GDP  tstatistic  ARR  ARU  Profile  Stability  
Internal demand  
Investment, construction  Volume index (base 2010 = 100)  5.32  0.28  
% GDP  8.88  0.10  0.38  YES  YES  
Investment, equipment  Volume index (base 2010 = 100)  6.30  0.24  0.41  
% GDP  4.87  0.11  0.18  NO  
Productive capacity utilization  %  3.22  0.02  0.11  NO  
External sector  
Real effective exchange rate  Index 1999 I = 100  − 0.66  
Current account balance  Volume index (base 2010 = 100)  0.00  
% GDP  − 6.98  0.13  0.34  YES  YES  
Gross national savings  Volume index (base 2010 = 100)  0.97  
% GDP  − 1.64  
Prices  
CPI, general  Price index (base 2011 = 100)  25.22  0.25  0.87  
Growth rate, % change  0.03  
GDP deflator  Price index (base 2011 = 100)  1.34  
Growth rate, % change  0.02  
Housing prices  Euros per square meter  2.26  0.29  
Labour market  
Unemployment rate  %  − 7.59  0.06  0.23  YES  YES 
Employment, fulltime equivalent  Thousands  3.17  0.28  
Hours worked per employee  Units  0.27  
Compensation per employee  Euros per employee  1.59  
Compensation of employees  Volume index (base 2010 = 100)  1.84  
M€  1.71  
Financial and monetary sector  
Credit to nonfinancial corporations  Volume index (base 2010 = 100)  − 0.14  
M€  0.23  
% GDP  − 1.44  
Credit to households  Volume index (base 2010 = 100)  − 0.19  
M€  0.43  
% GDP  − 1.58  
Broad money (M3 aggregate)  M€  0.12  
% GDP  5.43  0.13  1.54  
Narrow money (M1 aggregate)  M€  − 0.22  
% GDP  − 1.55  
Fiscal variables  
Public debt, excessive deficit procedure  Volume index (base 2010 = 100)  − 2.57  0.31  
M€  − 6.93  0.29  
% GDP  − 8.23  0.25  0.36  NO  
Net lending (+), net borrowing (−): general government  Volume index (base 2010 = 100)  0.00  
M€  − 0.01  
% GDP  1.11  
Taxes on production and imports  Volume index (base 2010 = 100)  0.47  
M€  1.92  0.20  0.92  
% GDP  − 3.95  0.10  0.07  NO  
Taxes on income and wealth  Volume index (base 2010 = 100)  
M€  0.06  
% GDP  2.14  0.11  0.12  NO  
Social contributions  Volume index (base 2010 = 100)  
M€  1.90  0.26  
% GDP  − 5.43  0.10  0.20  NO  
Unemployment benefits  Volume index (base 2010 = 100)  
M€  − 0.75  
% GDP  − 8.84  0.04  0.18  NO  
Net income  Volume index (base 2010 = 100)  
M€  6.41  0.26  
% GDP  − 5.12  0.16  0.16  NO 
The average revision indicator provides the second screening for the remaining variables. This indicator reflects the average gap between the filtered (onesided) and smoothed (twosided) estimates of the output gap, normalized by the maximum range of the filtered estimation. Variables experimenting large revisions relative to their volatility are thus penalized (e.g. public debt, housing prices). The defining threshold is set at 0.25, to include twothirds of the remaining sample. Third, goodness of fit is assessed in relative terms as the ratio between the average standard error and the maximum range of the filtered estimate. Again, the threshold is set to keep twothirds of the competing variables (at 0.4). Prices and monetary variables are discarded at this stage as can be seen in Table 2.
Once the necessary conditions are checked out, the fourth criterion looks at the amplitude and profile of the output gap estimates. Small cycles, as defined by a small amplitude (lower than 4 pp.) are first left out. These include productive investment and most of the remaining fiscal variables (net income, social security contributions, direct and indirect taxes). A closer look at the specific profiles and ECRI dating allows for a further screening by removing unemployment benefits (as it does not properly identify the beginning of the last cycle) and capacity utilization (as it advances the recovery after the last cycle and points to positive output gap figures already in 2016).
Only three candidates made it all the way down to the fourth criteria: (i) the unemployment rate; (ii) the current account balance over GDP; and (iii) investment in construction over GDP.
4.3 An estimate for Spain
4.3.1 Bivariate models
The estimation of bivariate models including GDP and each one of the selected candidate variables yields additional information on the shape and the extent of the cycle, as well as insights on the stability of the estimates. Thus, bivariate models operate as a pairwise, useful screening device for the complete multivariate model but the estimates of their parameters do not condition in any way the estimation of the corresponding parameters of the multivariate model.
This pseudoreal time exercise translates into updated output gap estimates as new data points are added to the sample (see righthand side of Fig. 3). A general pattern emerges in all three cases as new observations are considered: the peak of the last cycle is revised upwards and the trough is equally revised downwards, thus amplifying the extent of the crisis and delaying the closure of the output gap. These results are particularly relevant as they point towards structural gains associated with the latest economic developments.
4.3.2 Economic interpretation
The economic narrative also supports the interpretation of the current slack in the economy being rather large and with a slow reversion towards a balanced state.
In particular, the current growth pattern is proving to be resilient and balanced. Growth is more exportoriented and deleveraging in the private sector is coexisting with a robust productive investment and strong employment creation without generating inflationary or wage pressures.
The identification of a new growth pattern has important fiscal implications going ahead. Cyclical fluctuations do not have a constant impact on the budget balance as the response (elasticity) of fiscal revenues to growth is ultimately affected by compositions effects, as shown in Bouthevillain et al. (2001) and Bénétrix and Lane (2015). For example, when growth is more exportoriented, VAT revenues will respond less prociclically.
4.3.3 A final multivariate estimate
When turning from the bivariate to the full model setup, which includes GDP altogether with the three selected variables, the transition is far from smooth. Collinearity amongst the cyclical components can potentially generate imprecise point estimates that, combined with a flat likelihood function, may cause “jumps” in the estimations, rendering output gap estimates unstable.^{14}
In particular, instability is directly related with the estimates of the autoregressive dynamics of the cyclical component of GDP (\( \phi \) parameters in Eq. 4). A practical and operational fix consists in incorporating additional information in the estimation process. For this purpose, model averaging through the more stable bivariate estimates is performed.^{15}
Final ML estimation of the multivariate (v4) model.
Source of data: author’s estimations
Variable  Component  Parameters  Estimate  

Point  S.E.  
GDP  Trend  σ_{v}  0.0010  0.0003 
Drift  σ_{w}  0.0010  0.0004  
Cycle  σ_{e}  0.0017  0.0005  
ϕ1  1.8638  …  
ϕ2  − 0.8685  …  
Unemployment rate  Trend  σ_{v}  0.0035  0.0004 
Cycle  σ_{e}  0.0011  0.0003  
α  − 1.1456  0.3754  
Residential investment  Trend  σ_{v}  0.0028  0.0002 
Cycle  σ_{e}  0.0005  0.0003  
α  0.9845  0.1102  
Current account balance  Trend  σ_{v}  0.0044  0.0001 
Cycle  σ_{e}  0.0024  0.0009  
α  − 1.0193  0.6780 
Diagnostics for the multivariate (v4) model
Source of data: author’s estimations
Variable  Box–Ljung Q statistic at lag:  Skewness  Jarque–Bera  e2: Q(12)  

4  8  12  Kurtosis  
GDP  1.40  11.28  12.74  3.34  0.02  0.76  12.90 
0.84  0.19  0.39  0.69  0.38  
Unemployment rate  1.73  12.71  17.80  7.42  0.15  124.00  14.52 
0.79  0.12  0.12  0.00  0.27  
Residential  3.28  7.37  9.10  5.77  0.35  51.72  17.61 
Investment  0.51  0.5  0.69  0.00  0.13  
Current account balance  1.88  3.14  7.02  9.52  0.65  280.37  6.57 
0.76  0.92  0.86  0.00  0.88 
The final results present several benefits, easily passing the “smell test”. First, the estimate is in accordance with official recession dating, providing thus sensible turning point signals. Second, it is well aligned with external estimations, although some of them are twosided filters and thus include additional information. Third, it is highly reliable in realtime as the revisions are rather limited. Fourth, the expert judgement of its characterization of the last cycle seems appropriate, with an exceptional boombust episode, larger than initially thought, as can be seen through the comparison between the corresponding onesided and twosided estimates.
5 Conclusions
Over the last decades, the estimation of the slack in the economy has become an essential piece of analysis for policymakers, both on the monetary and the fiscal policy side. Output gap estimation techniques have flourished accordingly, although there is no consensus on a bestperforming methodology, as the selection criteria often imply important tradeoffs.
This paper presents a novel approach putting the focus on the specification of the model (“beauty contest” amongst candidate variables) rather than on a prior selection of the methodology itself (model “horse race”). Ideally, an agreeable method should achieve three necessary conditions: economic soundness, statistical goodness and transparency. On top of this, a sufficient condition for its final estimate of the cycle is given by the smell test, often implemented by policymakers. In practice, fulfilling these conditions can prove to be challenging.
Multivariate methods, coupled with Kalman filtering are generally considered amongst those reaching an acceptable level of compromise between these dimensions and thus are selected as a starting point, allowing for a combination of an economicallysound specification with a welltested and flexible econometric procedure. The method serves as a compromise as it fulfils the necessary criteria and allows for enough flexibility to get a countryspecific approximation to the sufficient (smell test) criteria as it could accommodate specific cycles (financial, external, investment, fiscal, etc.). This somewhat eclectic approach is illustrated with its application to a data set for the Spanish economy, by selecting the best model amongst combinations of GDP and 52 accompanying variables.
Some preliminary conclusions can be drawn at this stage. First, there are some technical aspects related to the specification of the variables that are important to be taken care of before jumping into the estimation, such as: (i) modeling of GDP as an integrated process of order 1 or 2; (ii) definition of the cyclical interactions (e.g. are all the cyclical components contemporaneous with the output gap?); (iii) transformation of the series (nominal vs. real, ratios vs. logs, etc.). Second, there is no clear algorithm for the selection of the variables to be included in the final specification. Should it be an incrementalistic approach or rather a brute force consideration of all the alternative combinations? Third, this paper has opted for the definition of necessary versus sufficient conditions, although other combinations or weighting of the criteria might be possible.
Finally, future extensions of this work include an attempt at answering some of these open questions and providing a full assessment of the methodology in more complex data environments as well as technical improvements adding to the existing selection criteria, for example by estimating the contribution of the observables to the estimation of the output gap, along the lines exposed by Koopman and Harvey (2003).
Footnotes
 1.
 2.
See for example Cotis et al. (2005) and references within for a complete discussion.
 3.
In the Spanish case, GDP can be modeled following an I(1) structure plus a highly persistent Markovswitching drift, as shown in Cuevas and Quilis (2017). This specific structure can be linearly approximated by a random walk plus an evolving AR(1) drift.
 4.
This function solves nonlinear, unconstrained optimization programs. See “Appendix A” for details.
 5.
A large number of backasts are generated to produce an effective desensitization. The numerical implementation considers a number around 0.65T, being T the number of available observations.
 6.
When forecasts for t + 1, t + 2, etc. are considered, they can be considered as extrapolations of the information available at time t rather than genuine observations.
 7.
In order to integrate the whole estimation process and to be able to consider the different variable combinations, an Excel platform has been designed that integrates the database, the estimation functions in Matlab and a stability analysis (backtest).
 8.
Economic Cycle Research Institute recession dating: https://www.businesscycle.com/ecribusinesscycles/internationalbusinesscycledateschronologies.
 9.
Data limitations prevent us to perform a true real time exercise, including the impact of revisions of the raw data as well as revisions due to the (twosided) seasonal adjustment filter. Thus, strictly speaking, the exercise must be considered as a pseudoreal time one.
 10.
Nonaccelerating inflation and stabilizing external sector rate of unemployment: NAIRUE.
 11.
Apart from the numerical implementation of the maximum likelihood estimation, our approach may be considered as a simple yet flexible approach for a specification search whereas Doménech and Gómez is more focused on providing an econometric model for a set of key macroeconomic relationships (Okun’s law, Phillips curve and the cyclical comovement between investment and output).
 12.
The use of symmetric filters for seasonal adjustment introduces an additional source of revisions in the output gap estimates.
 13.
 14.
This interaction may explain the instability of the estimated model parameters that underlie the instability of the output gap estimate although the exact nature of the problem requires more extensive research.
 15.
As can be seen in “Appendix B”, the constraints ensure the cyclical nature of the model as well as make more persistent its impulse response function.
 16.
Min–Max range including Spanish Ministry of Economy, European Commission, OECD and IMF estimations.
 17.
See Abad and Quilis (2004) for a detailed exposition of the algorithm. We have used a univariate interpolator to construct monthly output gap estimates that can be processed by the algorithm.
Notes
References
 Abad A, Quilis EM (2004) Programs for cyclical analysis. User’s guide. National Statistical Institute, SofiaGoogle Scholar
 Alberola E, Estrada A, Santabárbara D (2013) Growth beyond imbalances. Sustainable growth rates and output gap reassessment, Bank of Spain, working paper no. 1313Google Scholar
 Alichi A (2015) A new methodology for estimating the output gap in the United Sates, IMF working paper series, working paper no. 144Google Scholar
 Álvarez LJ, GómezLoscos A (2017) A menu on output gap estimation methods, Bank of Spain, working paper no. 1720Google Scholar
 Bénétrix AS, Lane PR (2015) Financial cycles and fiscal cycles. Trinity economics papers tep0815, Trinity College Dublin, Department of EconomicsGoogle Scholar
 Boot JCG, Feibes W, Lisman JHC (1967) Further methods of derivation of quarterly figures from annual data. Appl Stat 16(1):65–75CrossRefGoogle Scholar
 Borio C, Disyatat P, Juselius M (2017) Rethinking potential output: embedding information about the financial cycle. Oxford Economic Papers 69(3):655–677Google Scholar
 Bouthevillain C, CourThimann P, Van den Dool G, De Cos PH, Langenus G, Mohr MF, Momigliano S, Tujala M (2001) Ciclically adjusted budget balances: an alternative approach, ECB working paper no. 77Google Scholar
 Caporello G, Maravall A (2004) Program TSW. Revised manual, Bank of Spain, occasional paper no. 0408Google Scholar
 Chow G, Lin AL (1971) Best linear unbiased distribution and extrapolation of economic time series by related series. Rev Econ Stat 53(4):372–375CrossRefGoogle Scholar
 Clark T (1987) The Cyclical Component of U.S. Economic Activity. Quart J Econ 102(4):797–814CrossRefGoogle Scholar
 Cotis JP, Elmeskov J, Mourougane A (2005) Estimates of potential output: benefit and pitfalls from a policy perspective. In: Rechling L (ed) Euro area business cycle: stylized facts and measurement issues. CEPR, Washington DCGoogle Scholar
 Cuevas A, Quilis E (2017) Nonlinear modelling of the Spanish GDP, AIReF working paper, no. 17/01Google Scholar
 Doménech R, Gómez V (2006) Estimating potential output, core inflation, and the NAIRU as latent variables. J Bus Econ Stat 24(3):354–365CrossRefGoogle Scholar
 Doménech R, Estrada A, GonzálezCalbet L (2007) Potential growth and business cycle in the Spanish economy: implications for fiscal policy, Working paper no. 05, International Economics Institute, University of ValenciaGoogle Scholar
 Durbin J, Koopman SJ (2001) Time series analysis by state space methods. Oxford University Press, OxfordGoogle Scholar
 Estrada A, Hernández de Cos P, Jareño J (2004) Una estimación del crecimiento potencial de la economía española, Bank of Spain, ocassional paper no. 0405Google Scholar
 Fernández RB (1981) Methodological note on the estimation of time series. Rev Econ Stat 63(3):471–478CrossRefGoogle Scholar
 Gómez V, Maravall A (1998) Guide for using the programs TRAMO and SEATS, Bank of Spain working paper no. 05Google Scholar
 Harding D, Pagan A (2006) Synchronization of cycles. J Econom 132:59–79CrossRefGoogle Scholar
 Harvey AC (1989) Forecasting, structural time series models and the Kalman filter. Cambridge University Press, CambridgeGoogle Scholar
 Kim CJ, Nelson CR (1999) State space models with regime switching. MIT Press, CambridgeGoogle Scholar
 Kitagawa G, Gersch W (1996) Smoothness priors analysis of time series. Springer, BerlinCrossRefGoogle Scholar
 Koopman SJ, Harvey AC (2003) Computing observation weights for signal extraction and filtering. J Econ Dyn Control 27(7):1317–1333CrossRefGoogle Scholar
 Kuttner KN (1994) Estimating potential output as a latent variable. J Bus Econ Stat 12(3):361–368Google Scholar
 MathWorks (2016) Optimization toolbox. The MathWorks, Inc., NatickGoogle Scholar
 Murray J (2014) Output gap measurement: judgement and uncertainty, U.K. Office for Budget Responsibility, working paper no. 5Google Scholar
Copyright information
Open AccessThis article is distributed under the terms of the Creative Commons Attribution 4.0 International License (http://creativecommons.org/licenses/by/4.0/), which permits unrestricted use, distribution, and reproduction in any medium, provided you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons license, and indicate if changes were made.