myresizeenv

# Forecasting inflation using
disaggregates and machine learning

Gilberto Boaretto
Dept. of Economics, PUC-Rio, Brazil
<EMAIL_ADDRESS>
Marcelo C. Medeiros
Dept. of Economics, UIUC, US
<EMAIL_ADDRESS>
(This draft: )

###### Abstract

This paper examines the effectiveness of several forecasting methods for
predicting inflation, focusing on aggregating disaggregated forecasts – also
known in the literature as the bottom-up approach. Taking the Brazilian case
as an application, we consider different disaggregation levels for inflation
and employ a range of traditional time series techniques as well as linear and
nonlinear machine learning (ML) models to deal with a larger number of
predictors. For many forecast horizons, the aggregation of disaggregated
forecasts performs just as well survey-based expectations and models that
generate forecasts using the aggregate directly. Overall, ML methods
outperform traditional time series models in predictive accuracy, with
outstanding performance in forecasting disaggregates. Our results reinforce
the benefits of using models in a data-rich environment for inflation
forecasting, including aggregating disaggregated forecasts from ML techniques,
mainly during volatile periods. Starting from the COVID-19 pandemic, the
random forest model based on both aggregate and disaggregated inflation
achieves remarkable predictive performance at intermediate and longer
horizons.

Keywords: inflation forecasting; disaggregated inflation; bottom-up approach;
data-rich environment; machine learning.

JEL Codes: C22, C38, C52, C53, C55, E37.

Acknowledgements: Boaretto thanks PUC-Rio, CAPES, CNPq, and FAPERJ for
financial support. Medeiros thanks CNPq and CAPES for financial support. We
thank Gustavo Araújo, Juliano Assunção, Daniel Coutinho, Marcelo Fernandes,
Eduardo Freitas, Cleomar Gomes, Fábio Gomes, João Victor Issler, Guilherme
Kira, Márcio Laurini, and Gabriel Vasconcelos for helpful comments as well as
all seminar participants of the Federal University of Uberlândia Webinar, PUC-
Rio Graduate Workshop, XXII Meeting of the Brazilian Society of Finance
(SBFin), Depep/BCB Webinar, Itaú Webinar, University of São Paulo at Ribeirão
Preto Seminar, and 44th Meeting of the Brazilian Econometric Society (SBE) for
numerous comments and suggestions.

###### Contents

  1. 1 Introduction
  2. 2 Forecasting methodology
    1. 2.1 “Traditional” inflation forecasting
    2. 2.2 Aggregation of disaggregated forecasts
    3. 2.3 Direct forecasting approach and expanding window scheme
  3. 3 Models and forecast evaluation
    1. 3.1 Models
      1. 3.1.1 Benchmarks
      2. 3.1.2 Shrinkage-based models
      3. 3.1.3 Factor models
      4. 3.1.4 FarmPredict
      5. 3.1.5 Complete subset regression (CSR)
      6. 3.1.6 Random forest (RF)
    2. 3.2 Model combinations via average of forecasts
    3. 3.3 Evaluation: metrics and test
  4. 4 Data and setup
  5. 5 Results
    1. 5.1 Entire period: forecasts from January 2014 to June 2022
    2. 5.2 Forecasts before and after of COVID-19 pandemic
    3. 5.3 Forecast of disaggregates and variable selection
      1. 5.3.1 Disaggregation into BCB categories
      2. 5.3.2 Disaggregation into IBGE groups
      3. 5.3.3 Disaggregation into IBGE subgroups
      4. 5.3.4 Further remarks
  6. 6 Conclusion
  7. A Groups and subgroups of the IPCA
  8. B Predictive variables
  9. C Forecast performance for disaggregates by horizon
    1. C.1 BCB disaggregates before and after the COVID-19 pandemic
    2. C.2 Groups
    3. C.3 Subgroups
  10. D Frequency of models with least squared forecast error

##  1 Introduction

Economists and econometricians aim to provide as accurate inflation forecasts
as possible by utilizing the most efficient approaches available. An important
question is whether considering disaggregated inflation in different markets
or economic classifications can enhance the forecasting performance for
aggregate inflation. At first, this approach could capture trend dynamics,
seasonality, and short-term changes more effectively (Espasa, Senra, and
Albacete, 2002). In other words, using subcomponents would allow the
econometric models to capture the heterogeneity underlying the aggregate
variable better (Bermingham and D’Agostino, 2014). Given an unknown data-
generating process, whether direct or indirect forecasting through aggregating
disaggregated forecasts can improve or not forecast accuracy is strictly an
empirical question (Lütkepohl, 1984; Hendry and Hubrich, 2011; Faust and
Wright, 2013). Nevertheless, a critical challenge that emerges is the increase
in estimation uncertainty. To mitigate this problem, we implement a
disaggregated analysis using machine learning (ML) methods that can deal with
the bias-variance trade-off. Studies such as Inoue and Kilian (2008), Garcia,
Medeiros, and Vasconcelos (2017), and Medeiros, Vasconcelos, Veiga, and
Zilberman (2021) point out the benefits of these techniques for inflation
forecasting. Our paper employs these techniques in the context of
disaggregated analysis, something scarcely explored in the literature.

The broad literature on inflation forecasting documents that the predictive
performance of survey-based forecasts is challenging to beat, especially in
the short-term horizons – current and immediate next months (Thomas, 1999;
Ang, Bekaert, and Wei, 2007; Croushore, 2010). Faust and Wright (2013) argue
that “purely subjective forecasts are in effect the frontier of our ability to
forecast inflation” because, besides private sectors and central banks having
access to econometric models, they add expert judgment to these models.
Consequently, “a useful way of assessing models is by their ability to match
survey measures of inflation expectations” (Faust and Wright, 2013). A
potential explanation for this phenomenon is that forecasters are likely to
have a richer information set than the econometrician employing a standard set
of macroeconomic variables as predictors for inflation (Del Negro and Eusepi,
2011). Thus, including revealed expectations among the predictors is a way to
exploit an information set that is not available. Baştürk, Çakmakli, Ceyhan,
and Van Dijk (2014), Altug and Çakmaklı (2016), Garcia, Medeiros, and
Vasconcelos (2017), Fulton and Hubrich (2021), and Bańbura, Leiva-León, and
Menz (2021) find evidence favorable to the incorporation of survey-based
forecasts into forecasting econometric models.

This paper examines the effectiveness of various forecasting methods for
predicting aggregate inflation, focusing on aggregating disaggregated
forecasts – also known in the literature as the bottom-up approach. Using the
Brazilian case as an example, we compare the predictive performance of the
bottom-up approach with traditional approaches in the literature, including
survey-based forecasts and direct forecasting based exclusively on the
aggregate. We explore different levels of disaggregation to assess how
forecasts based on disaggregate price levels fare relative to those that rely
solely on aggregate. Granularity is a potential advantage of considering
disaggregates. Besides the specific effects of the traditional macro-variables
related to money, economic activity, government, and external sector, we
include lagged and crossed effects between disaggregates. When we compute our
forecasts, we also consider available survey-based expectations as a predictor
to add information not captured by other variables. Finally, we employ a range
of traditional time series techniques, as well as linear and nonlinear ML
techniques to deal with a larger number of predictors. More specifically, we
consider these modeling possibilities:

  1. 1.

Traditional time series methods: random walk (RW), historical mean, and
autoregressive (AR) models;

  2. 2.

Shrinkage-based models with or without sparsity, namely, Ridge and adaptive
LASSO (adaLASSO);

  3. 3.

Factor and target factor augmented models;

  4. 4.

FarmPredict, a model that bridges both common factor and sparsity structures.
With this method, we can explore remaining sparse idiosyncratic effects after
controlling for common factors, and autoregressive, expectation and
deterministic components;

  5. 5.

Complete subset regression (CSR), an ensemble method that combines estimates
from all possible linear regression models keeping the number of predictors
fixed;

  6. 6.

Random forest (RF), a bagged ensemble of non-linear tree-based models;

  7. 7.

Model combination via an average of forecasts for each disaggregation.

The Brazilian case is interesting for several reasons. First, the Broad
Consumer Price Index (Índice de Preços ao Consumidor Amplo – IPCA), which
serves as the official Brazilian price index, is available monthly and boasts
a rich structure to be explored. The index contains several disaggregation
levels and all time-varying weights of goods and services in the
representative consumption basket are readily available. Second, the Central
Bank of Brazil conducts the Focus survey, an extensive daily survey of
expectations for multiple forecast horizons for some variables, including
inflation. This survey reflects experts’ opinions, mainly financial market
professionals, and may contain private information that is not available to
the econometrician. Beyond its utility as a predictor for generating model-
based forecasts, Focus’ inflation expectations can be used as a benchmark to
assess whether improving survey-based forecasts for a given horizon is
possible. Third, due to Brazil’s inflationary history, in addition to the
official price index, the country has several price indexes that may be used
as predictors for inflation. Hence, it is pertinent to examine whether this
information is valuable for forecasting Brazilian inflation over future
horizons.

##### Findings.

Among the main results of this paper are:

  1. (i)

It is challenging to outperform the survey-based forecast (Focus) before the
COVID-19 pandemic; however, it is achievable post-pandemic (including at short
horizons);

  2. (ii)

Taking disaggregated inflation into account tends to generate forecasts as
good as survey-based expectations and forecasts based on aggregate inflation
directly;

  3. (iii)

Overall, ML methods tend to outperform traditional time series models in
predictive accuracy, with outstanding performance in predicting disaggregates;

  4. (iv)

There exists high variability in the type of predictors selected by the
adaLASSO and FarmPredict;

  5. (v)

The available survey-based inflation expectations and price variables are
relevant predictors;

  6. (vi)

Starting from the pandemic, the RF using aggregate inflation or some
disaggregation achieves remarkable predictive performance at intermediate and
longer horizons.

##### Contributions for the literature.

We can summarize the main contributions of this paper in two fields. First,
this paper advances the literature on inflation forecasting via aggregation of
disaggregated forecasts by considering many predictors for each disaggregate,
as well as several statistical and econometric methods underexplored in this
literature. Many papers employ traditional time series models and a limited
number of predictors. In this context, some papers find evidence favoring the
bottom-up approach for the Euro Area (Espasa, Senra, and Albacete, 2002;
Espasa and Albacete, 2007) and various countries (Bruneau, De Bandt,
Flageollet, and Michaux, 2007; Moser, Rumler, and Scharler, 2007; Capistrán,
Constandse, and Ramos-Francia, 2010; Aron and Muellbauer, 2012; Carlo and
Marçal, 2016; Fulton and Hubrich, 2021). On the other hand, some papers find
that aggregating forecasts by components does not necessarily improve
aggregate inflation forecasting (Benalal, Diaz del Hoyo, Landau, Roma, and
Skudelny, 2004; Hubrich, 2005; Hendry and Hubrich, 2011). In turn, Duarte and
Rua (2007), Ibarra (2012), and Bermingham and D’Agostino (2014) highlight the
benefits of aggregating a large number of disaggregates. By employing a large
number of predictors, Florido (2021, Chapter 1) points out the benefits of the
disaggregated analysis in inflation nowcasting, while Araujo and Gaglianone
(2023) do not find good results by using a disaggregation in multi-period
forecasting. We show that the bottom-up approach can generate multi-period
forecasts as accurately as survey-based expectations and direct forecasts.

Second, our analysis extends the literature on machine learning (ML) benefits
to forecasting inflation by showing a useful application of these methods
considering the aggregation of disaggregated forecasts in a data-rich
environment. The employ of ML methods to directly forecast inflation started
with factor and principal component models (Stock and Watson, 1999, 2002;
Forni, Hallin, Lippi, and Reichlin, 2003; Bai and Ng, 2008; Ibarra, 2012), and
neural network models (Moshiri and Cameron, 2000; Nakamura, 2005; Choudhary
and Haider, 2012). Several other papers expanded the list of methods to
shrinkage-based models (e.g., Ridge and LASSO), Bayesian methods, bagging,
boosting, random forest (RF), and complete subset regressions (CSR), but
keeping focus on forecast inflation directly from the aggregate (Inoue and
Kilian, 2008; Medeiros, Vasconcelos, and Freitas, 2016; Garcia, Medeiros, and
Vasconcelos, 2017; Zeng, 2017; Baybuza, 2018; Medeiros, Vasconcelos, Veiga,
and Zilberman, 2021; Araujo and Gaglianone, 2023). Florido (2021, Chapter 1)
considers ML techniques, disaggregated inflation, and a broad set of
predictors in inflation nowcasting, finding good results. Araujo and
Gaglianone (2023) consider the inflation disaggregated into administered
prices, services, industrial goods, and food at home to generate multi-horizon
inflation forecasts employing several ML models. However, their results are
not favorable to the bottom-up approach. In contrast, our combination between
disaggregated analysis, ML, and many predictors yields promising results and
opens up new possibilities for further exploration.

We also point out five other minor contributions. First, we corroborate the
findings of Baştürk, Çakmakli, Ceyhan, and Van Dijk (2014), Altug and Çakmaklı
(2016), Garcia, Medeiros, and Vasconcelos (2017), Fulton and Hubrich (2021),
and Bańbura, Leiva-León, and Menz (2021) regarding the benefits of
incorporating a survey-based expectation as a predictor when econometrician
computes their forecasts. The presence of this variable is relevant to improve
predictive accuracy even for some disaggregation levels. Second, when
estimating a factor-augmented autoregression model using a method that allows
predictor selection, we find that the factor that summarizes most of the
predictors’ variability is not relevant for predicting inflation. Hence, using
an estimation method such as the adaLASSO or the approaches of Bai and Ng
(2008, 2009) instead of least squares may be beneficial. Third, our paper is
one of the first to employ the FarmPredict, a model proposed by Fan, Masini,
and Medeiros (2021) that combines factor and sparse linear regressions. We
adapt it to allow the simultaneous estimation via adaLASSO of a final model
containing lags, common factors, and idiosyncratic components. Fourth, as in
Duarte and Rua (2007), Ibarra (2012), and Bermingham and D’Agostino (2014), we
also indicate the potential benefits of considering a high level of
disaggregation. However, there are caveats about how to improve the bottom-up
approach by considering different models predicting different disaggregates.
Finally, our analysis underscores the importance of examining sub-periods and
emphasizing the benefits of model-based forecasts in volatile periods, as also
pointed out by Altug and Çakmaklı (2016) and Medeiros, Vasconcelos, Veiga, and
Zilberman (2021).

##### Outline.

This paper has five more sections in addition to this Introduction. Section 2
presents the forecasting methodology, and Section 3 describes the models,
estimation, metrics, and test to compute and assess the results. Section 4
displays the data and setup. Section 5 presents the results and provides an
economic discussion about them. Finally, Section 6 concludes. Appendixes from
A to D offer supplementary information and complementary results.

##  2 Forecasting methodology

###  2.1 “Traditional” inflation forecasting

Let $\pi_{t}$ be the (aggregate) inflation at period $t$. We compute the
inflation from the percentage change in a price index based on a typical
consumption basket. For forecasting purposes, assume there are $J$ predictors
for inflation. Let $\boldsymbol{z}_{t}$ be a $J$-dimensional vector of these
explanatory variables observed at $t$, that is, the information set available
to the econometrician to perform the forecasting. Notice that
$\boldsymbol{z}_{t}$ can contain both the last available realizations of the
predictor variables as well as lags of these variables. Lastly, let
$\mathcal{M}_{t,h}$ be a time-varying mapping between explanatory variables
(predictors) and inflation $h$ periods ahead. As the estimation is based on
moving windows, the mapping is dependent on time, which we indicate by the
subscript $t$.

There are several possibilities to estimate the mapping $\mathcal{M}_{t,h}$.
Initially, we choose between linear or non-linear specifications. In a rich-
data environment, we can consider dimensionality reduction or shrinkage with
or without selecting predictors. Whatever the choices, we must be careful to
avoid overfitting. Finally, an $h$-period-ahead forecast is given by

$\displaystyle\widehat{\pi}_{t+h\,|\,t}=\widehat{\mathcal{M}}_{t,h}\big{(}\boldsymbol{z}_{t}\big{)}$

where hats indicate estimation.

###  2.2 Aggregation of disaggregated forecasts

Besides the general price index and their percentage change, the aggregate
inflation $\pi_{t}$, now consider the availability of $N^{d}$ disaggregated
price indexes (subcomponents of the original price index) indexed by
$i=1,\dots,N^{d}$. The letter $d$ indicates the disaggregation level. Let
$\pi_{it}^{d}$ be the percentage change of the disaggregate $i$ in
disaggregation level $d$ at period $t$. Let $\omega_{it}^{d}$ be the weight of
the disaggregate $i$ at disaggregation level $d$ in the general price index at
period $t$. Note that these weights are time-varying since the composition of
the representative consumption basket may change over time. The relationship
between inflation and price changes in disaggregated indexes is given by

$\displaystyle\pi_{t}=\sum_{i=1}^{N^{d}}\omega_{it}^{d}\,\pi_{it}^{d},$ (2.1)

that is, aggregate inflation is a weighted average of “disaggregated
inflations” (price changes).

Let $\boldsymbol{z}_{t}^{d}$ be a $J^{d}$-dimensional vector of all
explanatory variables for price changes observed at $t$ by the econometrician
at disaggregation level $d$. Note that it is expected that $J^{d}>J$ since in
the disaggregated case we potentially have more information: in addition to
all the other explanatory variables available in the aggregated case, we can
use the lagged price changes of the other disaggregates as predictors for a
specific disaggregate. The question arises as to whether capturing and
exploring the crossed dependence between disaggregated prices could enhance
inflation forecasting. Let $\mathcal{M}_{i,t,h}^{d}$ be a time-varying mapping
between predictors and $h$-period-ahead price variation of each disaggregate
$i=1,\dots,N^{d}$ at disaggregation level $d$. Following (2.1), an $h$-period-
ahead forecast for aggregate inflation is given by

$\displaystyle\widehat{\pi}_{t+h\,|\,t}=\sum\limits_{i=1}^{N^{d}}\widetilde{\omega}_{it}^{d}\,\widehat{\pi}_{i,t+h}=\sum_{i=1}^{N^{d}}\widetilde{\omega}_{it}^{d}\,\widehat{\mathcal{M}}_{i,t,h}^{d}\big{(}\boldsymbol{z}_{t}^{d}\big{)},$

where $\widetilde{\omega}_{it}^{d}$ is the weight of the disaggregate $i$ at
disaggregation level $d$ in aggregate index observed at $t$ by the
econometrician, that is, the last available weight at period $t$ and not the
weight evaluate for the period $t$ – which we previously indicate simply by
$\omega_{it}^{d}$.

###  2.3 Direct forecasting approach and expanding window scheme

We employ a direct forecast approach considering expanding windows for
(monthly) horizons $h\in\\{0,1,\dots,11\\}$. We take the time-adjusted
predictors to fit the mapping between them and inflation in this approach. For
example, suppose we want to generate a forecast for the current period
($h=0$), which is called nowcasting. In that case, we consider the most
recently available information to estimate the desired mapping. Conversely,
when computing a one-month-ahead forecast ($h=1$), we use the information
available up until the preceding period in which the forecast is estimated. We
continue this way until we calculate the forecast for $h=11$, utilizing
information available ten periods prior. Figure 1 illustrates the exercise.
Following the computation of forecasts based on a given period, we advance the
time window by one period and repeat the estimation procedure for each
forecast horizon, subsequently calculating new forecasts.

Figure 1: Direct forecasting approach with expanding window scheme

Notes: $y$ indicates the target variable. $\boldsymbol{X}$ represents
predictor variables. Subscripts “is” and “oos” denote in-sample and out-of-
sample, respectively.

##  3 Models and forecast evaluation

###  3.1 Models

To enhance clarity in presenting the following forecast methods, we omit the
superscript $d$ that indicates the level of disaggregation, whenever
applicable.

####  3.1.1 Benchmarks

##### Random walk (RW).

Considering the aggregated case, the forecast of the $h$-period-ahead
inflation at period $t$ is given by current inflation, that is,
$\widehat{\pi}_{t+h\,|\,t}^{\,\text{RW}}=\pi_{t}$.

##### Historical mean.

Also for the aggregated case, a prediction for $h$ periods ahead is given by
historical average inflation computed at $t$, that is,

$\displaystyle\widehat{\pi}_{t+h\,|\,t}^{\,\text{Hist.\,Mean}}=\overline{\pi}_{t+h\,|\,t}=\frac{1}{S}\sum_{s\,=\,t-S+1}^{t}\pi_{s}$

where $S$ is the number of previously observed inflation measures (expanding
window length).

##### Autoregressive model – AR($p$).

For both aggregated and disaggregated cases, in the direct forecast approach,
for each horizon $h$, we can be written a $p$-order AR model as

$\displaystyle\pi_{t}=\mu+\sum_{l=1}^{p}\phi_{l}\,\pi_{t-h-l+1}+\varepsilon_{t}$

where $\varepsilon_{t}$ is an error term. The order $p$ can be previously
fixed or selected via some information criterion (e.g., BIC). Thus, a
$h$-period-ahead inflation forecast is given by

$\displaystyle\widehat{\pi}_{t+h\,|\,t}^{\,\text{AR}}=\widehat{\mu}+\sum_{l=1}^{p}\widehat{\phi}_{l}\,\pi_{t-h-l+1}.$

where $\widehat{\mu}$ and $\widehat{\phi}$’s are least squares (OLS)
estimates.

##### Augmented autoregressive model.

Including seasonal dummies and inflation expectation, we can write the model

$\displaystyle\pi_{t}=\mu+\sum_{l=1}^{p}\phi_{l}\,\pi_{t-h-l+1}+\eta\;\pi_{t\,|\,t-h}^{e}+\sum_{m=1}^{11}\delta_{m}\,d_{mt}+\varepsilon_{t}$
(3.1)

where $\pi_{t\,|\,t-h}^{e}$ is the inflation expectation for the period $t$
available at $t-h$, $d_{mt}$ is a seasonal dummy that assumes value 1 for
month $m$, and $\delta_{m}$ is a coefficient associated with seasonal dummy
$d_{mt}$. In this framework, we estimate the coefficients via OLS, and a
$h$-period-ahead forecast is given by

$\displaystyle\widehat{\pi}_{t+h\,|\,t}^{\,\text{Aug.\,AR}}=\widehat{\mu}+\sum_{l=1}^{p}\widehat{\phi_{l}}\,\pi_{t-l+1}+\widehat{\eta}\;\pi_{t+h\,|\,t}^{e}+\sum_{m=1}^{11}\widehat{\delta}_{m}\,d_{m,t+h}.$

##### (Empirical) Hybrid New Keynesian Phillips curve (HNKPC).

Following and adapting price-setting models such as those presented in Galí
and Gertler (1999) and Blanchard and Galí (2007), we employ a forecasting
model for the aggregate inflation based on a hybrid Phillips curve given by

$\displaystyle\pi_{t}=\mu+\sum_{l=1}^{p}\phi_{l}\,\pi_{t-h-l+1}+\eta\,\pi_{t\,|\,t-h}^{e}+\psi_{1}\,g_{t-h}+\psi_{2}\,\Delta
s_{t-h}+\varepsilon_{t}$

where $g_{t-h}$ is some economic activity measure observed at $t-h$, and
$\Delta s_{t-h}$ is an exchange rate measure observed at $t-h$. We compute the
forecast by

$\displaystyle\widehat{\pi}_{t+h\,|\,t}^{\,\text{HNKPC}}=\widehat{\mu}+\sum_{l=1}^{p}\widehat{\phi}_{l}\,\pi_{t-l+1}+\widehat{\eta}\,\pi_{t+h\,|\,t}^{e}+\widehat{\psi}_{1}\,g_{t}+\widehat{\psi}_{2}\,\Delta
s_{t}$

where
$\big{(}\widehat{\mu},\,\widehat{\boldsymbol{\phi}},\,\widehat{\eta},\,\widehat{\psi}_{1},\,\widehat{\psi}_{2}\big{)}$
are OLS estimates.

####  3.1.2 Shrinkage-based models

##### Ridge (with incomplete information).

For disaggregated cases, we consider the augmented AR model (3.1) with the
addition of other lagged disaggregates:

$\displaystyle\pi_{it}=\mu+\sum_{i^{\prime}=1}^{N^{d}}\sum_{l=1}^{p}\phi_{i^{\prime}l}\,\pi_{i^{\prime},t-h-l+1}+\eta_{i}\,\pi_{t\,|\,t-h}^{e}+\sum_{m=1}^{11}\delta_{im}\,d_{mt}+\varepsilon_{it}\qquad
i=1,\dots,N^{d},$

where $N^{d}$ is the number of subcomponents in the disaggregation level
indicated by $d$. We consider four disaggregation levels in this paper:
aggregate inflation, economic categories defined by the BCB, and groups and
subgroups from IPCA (IBGE).

We estimate the coefficients employing the Ridge estimator:

$\displaystyle\left(\widehat{\mu}_{i},\,\widehat{\boldsymbol{\beta}}_{\text{Ridge},i}(\lambda)\right)=\operatorname*{\mathsf{argmin}}_{\mu_{i},\,\boldsymbol{\beta}_{i}}\left\\{\frac{1}{T-h}\sum_{t=1}^{T-h}\left(\pi_{it}-\mu_{i}-\boldsymbol{\beta}_{i}\,\boldsymbol{z}_{t-h}\right)^{2}+\lambda_{i}\sum_{j=1}^{J}\,\beta_{ij}^{2}\right\\}$

where $\lambda_{i}$ is a regularization parameter, $\boldsymbol{z}_{t-h}$ is a
vector with all predictors, and $\boldsymbol{\beta}_{i}$ is a vector of
coefficients. Chosen $\lambda$ via information criteria (e.g., BIC), a
prediction for $h$ periods ahead is given by

$\displaystyle\widehat{\pi}_{t+h\,|\,t}^{\,\text{Ridge}}=\sum_{i=1}^{N^{d}}\omega_{it}\,\widehat{\pi}_{i,t+h\,|\,t}^{\,\text{Ridge}}\qquad\text{with}\qquad\widehat{\pi}_{i,t+h\,|\,t}^{\,\text{Ridge}}=\widehat{\mu}_{i}+\widehat{\boldsymbol{\beta}}_{\text{Ridge},i}\,\boldsymbol{z}_{t}.$

##### adaLASSO (with full information).

For all cases, consider the model with full information given by

$\displaystyle\pi_{it}=\mu_{i}+\sum_{i^{\prime}=1}^{N^{d}}\sum_{l=1}^{p}\phi_{i^{\prime}l}\,\pi_{i^{\prime},t-h-l+1}+\eta_{i}\,\pi_{t\,|\,t-h}^{e}+\sum_{m=1}^{11}\delta_{im}\,d_{mt}+\sum_{j=1}^{J}\sum_{l=1}^{p}\theta_{ijl}\,x_{j,t-h-l+1}+\varepsilon_{it}$

where $\boldsymbol{x}_{t-h}\in\mathbb{R}^{J\cdot p}$ is an expanded vector of
potential predictors for $\pi_{it}$. We estimate this model employing the
adaptive LASSO (adaLASSO). Introduced by Zou (2006), this method selects
predictors and their optimization problem is given by

$\displaystyle\left(\widehat{\mu}_{i},\,\widehat{\boldsymbol{\beta}}_{\text{adaLASSO}}(\lambda,\boldsymbol{\omega})\right)=\operatorname*{\mathsf{argmin}}_{\mu_{i},\,\boldsymbol{\beta}_{i}}\left\\{\frac{1}{T-h}\sum_{t=1}^{T-h}\left(\pi_{it}-\mu_{i}-\boldsymbol{\beta}_{i}\,\boldsymbol{z}_{t-h}\right)^{2}+\xi\sum_{j=1}^{V}\zeta_{ij}\,|\beta_{ij}|\right\\}$

where $\xi$ is a regularization parameter,
$\boldsymbol{z}_{t-h}\in\mathbb{R}^{V}$, $V=N^{d}\cdot p+12+J\cdot p$, is a
vector of all predictors, and $\boldsymbol{\zeta}=(\zeta_{1},\dots,\zeta_{V})$
is a vector of weights obtained previously employing LASSO – a estimator that
assumes $\zeta_{ij}=1$, for all $j$. More precisely, we compute the weights
via

$\displaystyle\zeta_{ij}=\left(\left|\widehat{\beta}_{\text{LASSO},ij}\right|+\frac{1}{\sqrt{T}}\right)^{-1},$

where we add $T^{-1/2}$ to allow a variable that is not selected in the first
stage to have a chance of being selected in the second stage.

As before, a $h$-period-ahead forecast is
$\widehat{\pi}_{i,t+h\,|\,t}^{\text{adaLASSO}}=\widehat{\mu}_{i}+\widehat{\boldsymbol{\beta}}_{\,\text{adaLASSO},i}\,\boldsymbol{z}_{t}$.

####  3.1.3 Factor models

##### (Augmented) factor model.

Consider that all regressors are normalized for both aggregate and
disaggregate cases. Thus, for $i=1,\dots,N^{d}$, a factor-augmented
autoregression model is described by

$\displaystyle\boldsymbol{x}_{t}=\sum_{k=1}^{K}\boldsymbol{\lambda}_{k}\,f_{kt}+\boldsymbol{u}_{t}$
(3.2)
$\displaystyle\pi_{it}=\mu_{i}+\sum_{i^{\prime}=1}^{D}\sum_{l=1}^{p}\phi_{i^{\prime}l}\,\pi_{i^{\prime},t-h-l+1}+\eta_{i}\,\pi_{t\,|\,t-h}^{e}+\sum_{m=1}^{11}\delta_{im}\,d_{mt}+\sum_{k=1}^{K}\beta_{ik}\,\widehat{f}_{k,t-h}+\varepsilon_{it}$

from which we compute common factors
$\widehat{\boldsymbol{f}}_{t}=\left(\widehat{f}_{1t},\dots,\widehat{f}_{Kt}\right)$
and factor loadings
$\boldsymbol{\lambda}_{k}=\left(\lambda_{1k},\dots,\lambda_{Jk}\right)$ by
combining principal component analysis (PCA) and OLS. Finally, we compute
$\big{(}\widehat{\mu}_{i},\,\widehat{\boldsymbol{\phi}},\,\widehat{\eta}_{i},\,\widehat{\boldsymbol{\beta}}\big{)}$
via adaLASSO.

For identification purposes, we assume that

$\displaystyle\mathbb{E}(\boldsymbol{f}_{t}\,|\,\boldsymbol{u}_{t})=0,\quad\operatorname{\mathrm{Cov}}(\boldsymbol{u}_{t},\varepsilon_{t})=0,\quad\operatorname{\mathrm{Var}}(\boldsymbol{f}_{t})=\boldsymbol{I}_{K},\quad\operatorname{\mathrm{Var}}(\boldsymbol{u}_{t})=\boldsymbol{\Omega}=\mathsf{diag}\,(\sigma_{1}^{2},\dots,\sigma_{p}^{2}).$

The number of factors $K$ is selected via information criterion
$\text{IC}_{p2}$ of Bai and Ng (2002), and the forecast $h$ periods ahead is
given by

$\displaystyle\widehat{\pi}_{i,\,t+h\,|\,t}^{\,\text{Factor}}=\widehat{\mu}_{i}+\sum_{i^{\prime}=1}^{D}\sum_{l=1}^{p}\widehat{\phi}_{i^{\prime}l}\,\pi_{i^{\prime},t-l+1}+\widehat{\eta}_{i}\,\pi_{t+h\,|\,t}^{e}+\sum_{m=1}^{11}\widehat{\delta}_{im}\,d_{m,t+h}+\sum_{k=1}^{K}\widehat{\beta}_{ik}\,\widehat{f}_{kt}$

where $\widehat{f}_{kt}$ is the $k$-th factor evaluated at $t$.

##### Target factor model.

Proposed by Bai and Ng (2008), in this “hard thresholding” version, this
approach controls for the participation of normalized explanatory variables in
the factor construction. In a previous stage, for each predictor indexed by
$j=1,\dots,J$, and disaggregate indexed by $i=1,\dots,N^{d}$, we estimate

$\displaystyle\pi_{it}=\mu_{i}+\sum_{i^{\prime}=1}^{N^{d}}\sum_{l=1}^{p}\phi_{i^{\prime}l}\,\pi_{i^{\prime},\,t-l}+\eta_{i}\,\pi_{t\,|\,t-h}^{e}+\sum_{m=1}^{11}\delta_{im}\,d_{mt}+\theta_{ij}\,x_{j,t-h}+\nu_{it}$

and run the hypothesis test $\theta_{ij}=0\,\times\,\theta_{ij}\neq 0$ for
some significance level $\alpha$. If $\theta_{ij}$ is statistically different
from zero, we employ $x_{j}$ in the factor estimation. Let
$\boldsymbol{x}_{t}(\alpha,i)$ be the set of selected variables for $i$-th
disaggregation. Finally, we proceed as in the traditional factor-augmented
autoregressive model: we perform

$\displaystyle\boldsymbol{x}_{t}(\alpha,i)=\sum_{k=1}^{K}\boldsymbol{\lambda}_{k}\,f_{kt}+\boldsymbol{u}_{t}$

which $\widehat{\boldsymbol{f}}_{t}$ and $\widehat{\boldsymbol{\lambda}}_{k}$
are computed via PCA and OLS. Then we estimate the augmented (target) factor
model via adaLASSO and compute the forecast as before.

####  3.1.4 FarmPredict

Some idiosyncratic errors of the factor model, that is, some
$\boldsymbol{u}_{t}$ entries in Equation (3.2), can impact the price
variation, which the common factor structure does not capture. Defining
$\widehat{\boldsymbol{u}}_{t}=\boldsymbol{x}_{t}-\sum_{k=1}^{K}\widehat{\boldsymbol{\lambda}}_{k}\,\widehat{f}_{k,t}$,
a $J$-dimensional vector, we can introduce lags of $\boldsymbol{u}_{t}$ on the
factor model:

$\displaystyle\pi_{it}=\mu_{i}\,+\,\sum_{i^{\prime}=1}^{N^{d}}\sum_{l=1}^{p}\phi_{i^{\prime}l}\,$
$\displaystyle\pi_{i^{\prime},t-h-l+1}+\gamma_{i}\,\pi_{t\,|\,t-h}^{e}+\sum_{m=1}^{11}\delta_{im}\,d_{mt}$
$\displaystyle+\sum_{k=1}^{K}\sum_{l=1}^{p}\beta_{ikl}\,\widehat{f}_{k,t-h-l+1}+\sum_{j=1}^{J}\sum_{l=1}^{p}\theta_{ijl}\,\widehat{u}_{j,t-h-l+1}+\varepsilon_{it}.$
(3.3)

This model is a specific form of a general model called FarmPredict proposed
by Fan, Masini, and Medeiros (2021). Here, we estimate the “final equation”
(3.3) with all regressors simultaneously employing the adaLASSO. Next, we
compute the forecast.

####  3.1.5 Complete subset regression (CSR)

Introduced by Elliott, Gargano, and Timmermann (2013, 2015), this ensemble
method combines estimates from all (or several) possible linear regression
models, keeping the number of predictors fixed. Let $p$ be the total available
predictors and $k\leqslant p$ be the number of “selected” predictors (complete
subsets). The CSR involves the estimation of $\frac{\textstyle
k!}{\textstyle(k-p)!k!}$ linear models. Variables when “non-selected” has
their coefficients set to zero. The final CSR estimate is the average of all
estimates. Thus, subset regression has a shrinkage interpretation since when
averaging parameters that sometimes assume zero value, this average generates
shrunken estimates of the coefficients, which can contribute to more accurate
forecasts. Due to the high computational cost arising from a large number of
predictors, we (pre-)select $\widetilde{p}\leqslant p$ predictors based on a
ranking of t-statistics in absolute value, as in Garcia, Medeiros, and
Vasconcelos (2017) and Medeiros, Vasconcelos, Veiga, and Zilberman (2021).
This procedure is similar to that used in the target factor model. So, instead
of considering all available $p$ predictors, we run the CSR considering
$\widetilde{p}$ pre-selected predictors.

####  3.1.6 Random forest (RF)

Breiman (2001) introduces the random forest (RF), a model that combines
several based-tree regressions using bagging. A regression tree is a
nonparametric model that approximates an unknown nonlinear function with local
predictions via recursive partitioning, as illustrated in Figure 2.

Figure 2: A regression tree with two explanatory variables $(X_{1},X_{2})$

Notes: $s_{i},\;i=1,\dots,4$, indicate splits, while $R_{k},\;k=1,\dots,5$,
denote regions. Example extracted from Medeiros, Vasconcelos, Veiga, and
Zilberman (2021).

Formally, a regression tree model can be written as follows:

$\displaystyle\pi_{it}=\sum_{k=1}^{K}c_{k}\,\mathcal{I}_{k}(\boldsymbol{x}_{t-h}\in
R_{k})$

where $\mathcal{I}_{k}(\boldsymbol{x}_{t-h}\in R_{k})$ is an indicator
function that assumes the value 1 when $\boldsymbol{x}_{t-h}$ belongs to the
$k$-th region $R_{k}$, and $c_{k}$ is the average of $\pi_{t}$ in this region.
We have to set the minimum number of observations per region. Then, we obtain
$B$ trees by implementing a double draw: we draw on the observation dimension
using block bootstrap, and we draw variables to incorporate in the estimation
of the tree. The idea is that this double draw will ensure the variability of
the trees. Let $K_{b}$ be the number of regions of the $b$-th tree,
$b=1,\dots,B$. Lastly, the final forecast is given by the average of the
forecasts obtained by each tree evaluated in the original data, that is,

$\displaystyle\widehat{\pi}_{i,\,t+h\,|\,t}^{\,\text{RF}}=\frac{1}{B}\sum_{b=1}^{B}\sum_{k=1}^{K_{b}}\widehat{c}_{k,b}\,\mathcal{I}_{k,b}(\boldsymbol{x}_{t-h}\in
R_{k,b})$

where $R_{k,b}$ is the $k$-th region of the $b$-th tree.

###  3.2 Model combinations via average of forecasts

Methods may perform differently for distinct disaggregates or even over time
for the same disaggregate. To mitigate instabilities associated with some
method for some disaggregate or at some point in time, for each
disaggregation, we will compute a combined forecast given by the average of
forecasts generated by all methods applied to this disaggregation and Focus
expectations available when the econometrician computes their forecasts, that
is,

$\displaystyle\widehat{\pi}_{t+h\,|\,t}^{\,\text{Comb},\,d}=\frac{1}{M^{d}+1}\left(\sum_{m=1}^{M^{d}}\sum_{i=1}^{N^{d}}\widetilde{\omega}_{it}^{d}\,\widehat{\pi}_{i,t+h\,|\,t}^{\,m,\,d}+\pi_{t+h\,|\,t}^{e}\right),$

where $d$ indicates one of four possible disaggregations levels addressed in
this paper (aggregate inflation, BCB categories, IBGE groups, and IBGE
subgroups), $m$ indicates a method, $M^{d}$ is the number of methods employed
to forecast the inflation for the disaggregation $d$, $N^{d}$ is the number of
disaggregates in the disaggregation $d$, and $\widetilde{\omega}_{it}^{d}$ is
the weight of disaggregate $i$ of the disaggregation level $d$ in the
aggregate index observed at $t$ by the econometrician. The idea is to
investigate whether this simple combination leads to improvements in forecast
performance.

###  3.3 Evaluation: metrics and test

##### Metrics.

We use out-of-sample root mean squared error (RMSE) as the main metric to
evaluate the forecast performance. For each horizon $h$, this metric is
described by

$\displaystyle\text{RMSE}_{h}^{\,m,\,d}=\left[\frac{1}{T}\sum_{t=1}^{T}\big{(}\pi_{t+h}-\widehat{\pi}_{t+h\,|\,t}^{\,m,\,d}\big{)}^{2}\right]^{1/2}$

where $\widehat{\pi}_{t+h\,|\,t}^{\,m,\,d}$ indicates a forecast generated by
the model $m$ considering the disaggregation level $d$. The smaller the
$\text{RMSE}_{h,\,m}$, the better the model’s predictive performance. For the
Diebold-Mariano test, we consider the mean squared error (MSE) defined by

$\displaystyle\text{MSE}_{h}^{\,m,\,d}=\frac{1}{T}\sum_{t=1}^{T}\big{(}\pi_{t+h}-\widehat{\pi}_{t+h\,|\,t}^{\,m,\,d}\big{)}^{2}.$

##### Test.

To assess the results, we consider the widely employed test developed by
Diebold and Mariano (1995). Let
$\widehat{v}_{t+h\,|\,t}^{\,m}=\pi_{t+h}-\widehat{\pi}_{t+h\,|\,t}^{\,m}$ be a
forecast error of the model $m$. Here, we omit the disaggregation level $d$.
Let $g(\cdot)$ be a metric to be applied to $\widehat{v}_{t+h\,|\,t,\,m}$
(e.g., MSE). The Diebold-Mariano (DM) test statistic is given by

$\displaystyle
d_{m,m^{\prime}}=\frac{1}{T}\sum_{t=1}^{T}\left(g\big{(}\widehat{v}_{t+h\,|\,t}^{\,m}\big{)}-g\big{(}\widehat{v}_{t+h\,|\,t}^{\,m^{\prime}}\big{)}\right)$

where $m^{\prime}$ indicates another model, a competitor (i.e., a benchmark
model or specific forecast, for example). We will consider that the normality
of DM statistics is likely a trustworthy approximation, including for model-
based forecasts.

##  4 Data and setup

##### Data.

We analyze the period from January 2004 to June 2022, totalizing 18,5 years of
monthly data. For aggregate inflation, we employ the IPCA, the official
Brazilian price index computed by the Brazilian Institute of Geography and
Statistics (Instituto Brasileiro de Geografia e Estatística – IBGE). For
disaggregations, we consider all groups and subgroups of the IPCA. There are
nine groups and 19 subgroups throughout the period analyzed. Subgroups are
subdivisions and, in some cases, the group itself. For definition of groups
and subgroups, and their respective average weights in the IPCA, see Table A1
in Appendix A. In addition, we use a disaggregation defined by the Central
Bank of Brazil (BCB) based on IBGE data. The BCB disaggregation consists of
administrated, non-tradables, and tradables items. The use of this last
disaggregation is interesting because, in principle, it presents more economic
intuition, which can contribute to better forecast performance.

We consider inflation expectations of the Central Bank of Brazil’s Focus
survey and lags of the predicted variables among the admissible predictors. To
forecast a disaggregate, we consider lags of other disaggregates in the same
disaggregation, which allows capturing potential lagged “cross-effects”. The
Focus survey has a daily frequency and contains inflation expectations formed
by many economic agents (experts) for several horizons (months) ahead.
Reflecting the opinion of experts, the Focus may contain private information
that is not available to the econometrician – hence the importance of
considering this variable in our information set. We consider the latest
available inflation expectation for the horizon of interest when we generate
our forecast. Moreover, there are eighty-nine other predictor variables (and
their lags) divided into ten categories: prices and money (17), commodities
prices (4), economic activity (19), employment (5), electricity (4),
confidence (3), finance (12), credit (4), government (12), and exchange and
international transactions (9). In Appendix B, Table B1 presents a description
of these variables, the delay for each to become available and transformations
implemented to guarantee the stationarity. We structure our dataset to closely
approximate real-time data for the Brazilian case. The main challenge lies in
our lack of access to the first releases of some economic activity variables,
including the IBC-Br (a Brazilian Economic Activity Index) and industrial
production (and their subcomponents).

##### Setup.

The reference day to compute our forecasts is the last business day of each
month. For the results shown in the following section, we consider three lags
for all predictive variables, including variables mentioned above, factors in
factor models, idiosyncratic components in FarmPredict, and lags of aggregate
and all disaggregates. The only exception is the factors in the target factor
model for which we employ only one (target) factor. As mentioned in Subsection
2.3, the main results are generated based on expanding windows. In this setup,
we generate 114 forecasts for each horizon. The regularization parameters
($\lambda$’s) of the Ridge, LASSO, and adaLASSO are obtained via Bayesian
Information Criterion (BIC). We restrict the number of possible selected
variables by the ceiling of $\sqrt{T}$ to enforce discipline. The number $K$
of latent factors in factor models is selected via Bai and Ng (2002)
information criterion $IC_{p2}$. For CSR, we set $\widetilde{p}=20$ (number of
pre-selected predictors) and $p=4$ (number of selected variables by CSR). For
pre-selecting of both target factor and CSR models, we adopt the 5%
significance level ($\alpha=0.05$). In its turn, for the RF models, we allow
the trees to grow until five observations by leaf. We set the proportion of
selected variables in each split to 1/3 and the number of bootstrap samples to
500 ($B=500$). All settings are similar to those adopted by Garcia, Medeiros,
and Vasconcelos (2017) and Medeiros, Vasconcelos, Veiga, and Zilberman (2021).
Finally, to estimate the empirical Phillips curve, we use the Central Bank of
Brazil’s economic activity index (IBC-Br) and BIS’ real effective exchange
rate (REER) as a proxy for economic activity and exchange rate, respectively.

##  5 Results

###  5.1 Entire period: forecasts from January 2014 to June 2022

Table 1 exhibits the results of forecast performance in terms of root mean
squared errors (RMSE) for different models and horizons ranging from
nowcasting ($h=0$) to eleven months ahead ($h=11$), as well as for 12-month
accumulated inflation. We normalize every RMSE to relative terms by computing
their ratio to the RMSE of the Focus consensus – the median expectation of the
available Focus survey. Thus, a value lower than one indicates that a model
numerically outperforms the Focus consensus, while a value greater than one
suggests underperformance compared to the same benchmark. At this first
moment, the results consider the entire period for which we compute
predictions, from January 2014 to June 2022. Each panel of Table 1 considers a
group of competitors. In panel A, we have the available and ex-post Focus, the
latter released by the Central Bank in the following week reflecting the
experts’ opinions on the same day we compute our forecasts. We note virtually
no difference between the available and ex-post Focus for longer horizons.
However, in the short term ($h\leqslant 3$), there is evidence that ex-post
Focus statistically outperforms available Focus. Despite being only a few days
apart, the informational gain is considerable for shorter horizons, which does
not occur for more distant periods since it is unlikely that very relevant
information about them will emerge within a few days.

Table 1: Out-of-sample RMSE with respect to the available Focus: Jan/2014 to
Jun/2022

Estimator/Model | $h=0\quad$ | $h=1\quad$ | $h=2\quad$ | $h=3\quad$ | $h=4\quad$ | $h=5\quad$ | $h=6\quad$ | $h=7\quad$ | $h=8\quad$ | $h=9\quad$ | $h=10\;\,$ | $h=11\;\,$ | $\Sigma\,12m$
---|---|---|---|---|---|---|---|---|---|---|---|---|---
A. Survey
Focus (available) | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000
Focus (ex-post) | $\textbf{{\color[rgb]{0,0,1} 0.933}}^{\,***}$ | $0.972^{\,***}$ | $0.993^{\,***}$ | 1.001 | 1.000 | 1.000 | 1.000 | 0.999 | 0.999 | 1.000 | 1.001 | 1.001 | 0.999
B. Aggregate inflation
RW | 2.782 | 1.471 | 1.212 | 1.251 | 1.279 | 1.271 | 1.234 | 1.180 | 1.087 | 1.063 | 1.102 | 1.138 | 1.485
Historical Mean | 3.117 | 1.342 | 1.084 | 1.053 | 1.034 | 1.018 | 0.998 | 0.990 | 0.987 | 0.983 | 0.982 | 0.984 | 1.041
AR | 2.534 | 1.260 | 1.053 | 1.077 | 1.090 | 1.064 | 1.008 | 0.961 | $0.939^{\,*}$ | $0.941^{\,*}$ | 0.964 | 0.988 | 0.987
HNKPC | $\textit{{\color[rgb]{0,0,1} 0.946}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.957}}^{\,**}$ | $0.972^{\,*}$ | 0.981 | 1.036 | 1.030 | 0.980 | 0.968 | $0.963^{\,*}$ | 0.974 | 0.998 | 1.021 | 0.984
Augmented AR | 0.970 | 0.981 | 0.989 | 1.012 | 1.023 | 0.999 | 0.963 | $\textit{{\color[rgb]{0,0,1} 0.943}}^{\,*}$ | $\textit{{\color[rgb]{0,0,1} 0.936}}^{\,**}$ | 0.961 | 0.993 | 1.016 | $0.954^{\,*}$
adaLASSO | $\textit{{\color[rgb]{0,0,1} 0.944}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.948}}^{\,***}$ | $0.978^{\,*}$ | 0.993 | $\textit{{\color[rgb]{0,0,1} 0.977}}^{\,**}$ | 0.989 | 0.976 | 0.976 | 0.989 | 1.004 | 1.043 | 0.992 | $0.961^{\,*}$
Factor | $\textit{{\color[rgb]{0,0,1} 0.943}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.931}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.966}}^{\,**}$ | $\textbf{{\color[rgb]{0,0,1} 0.964}}^{\,**}$ | 0.974 | 0.980 | 0.989 | 0.986 | 1.016 | 1.016 | 1.052 | 1.045 | 0.989
FarmPredict | $\textit{{\color[rgb]{0,0,1} 0.944}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.942}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.961}}^{\,**}$ | 0.987 | 0.999 | 1.001 | 1.004 | 1.020 | 1.020 | 1.032 | 1.027 | 1.051 | 1.001
Target Factor | 1.280 | 1.129 | 1.045 | 1.155 | 1.122 | 1.069 | $\textbf{{\color[rgb]{0,0,1} 0.937}}^{\,*}$ | 0.989 | 0.990 | 0.980 | 1.019 | 1.102 | 0.970
CSR | 0.961 | $\textbf{{\color[rgb]{0,0,1} 0.927}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.962}}^{\,*}$ | 0.983 | 1.022 | 0.996 | 0.969 | $\textit{{\color[rgb]{0,0,1} 0.940}}^{\,**}$ | $0.940^{\,**}$ | 0.975 | 1.042 | 1.071 | $0.935^{\,**}$
Random Forest | 1.665 | 1.110 | 1.025 | 1.012 | 0.996 | 0.987 | 0.959 | 0.949 | $\textbf{{\color[rgb]{0,0,1} 0.920}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.918}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.908}}^{\,**}$ | $\textbf{{\color[rgb]{0,0,1} 0.909}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.918}}^{\,*}$
C. Disaggregation: tradable, nontradable and monitored prices (BCB)
AR | 2.579 | 1.241 | 1.039 | 1.057 | 1.089 | 1.085 | 1.015 | 1.037 | 0.990 | 0.989 | 1.026 | 1.036 | 1.050
Augmented AR | 0.978 | 0.978 | 1.012 | 1.061 | 1.094 | 1.072 | 1.010 | 1.010 | 0.982 | 1.003 | 1.052 | 1.073 | 1.048
Ridge | 1.018 | 1.015 | 1.007 | 1.019 | 1.045 | 1.083 | 0.999 | 0.978 | 0.969 | $0.960^{\,*}$ | 1.013 | 0.981 | 1.032
adaLASSO | 1.099 | 0.998 | 0.968 | 0.969 | 0.977 | $\textit{{\color[rgb]{0,0,1} 0.948}}^{\,**}$ | $0.962^{\,*}$ | $0.957^{\,*}$ | 0.979 | 0.964 | 0.972 | $\textit{{\color[rgb]{0,0,1} 0.957}}^{\,*}$ | $\textit{{\color[rgb]{0,0,1} 0.903}}^{\,**}$
Factor | 1.023 | 0.988 | 0.991 | 0.990 | 0.977 | $\textbf{{\color[rgb]{0,0,1} 0.934}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.940}}^{\,**}$ | 0.977 | 1.000 | 1.007 | 1.009 | 1.009 | $0.943^{\,*}$
FarmPredict | 1.129 | 1.024 | 1.003 | 0.981 | 0.969 | $\textit{{\color[rgb]{0,0,1} 0.944}}^{\,**}$ | $0.956^{\,*}$ | 0.984 | 1.003 | 1.009 | 1.008 | 0.991 | 0.963
Target Factor | 1.331 | 1.052 | 0.976 | 1.090 | 1.131 | 1.079 | 0.943 | 0.962 | 0.964 | 0.991 | 1.016 | 1.077 | 0.936
CSR | 2.176 | 1.178 | 1.016 | 1.015 | 1.018 | 0.983 | 0.957 | 0.977 | 0.959 | 0.967 | 1.022 | 1.052 | 0.952
Random Forest | 1.934 | 1.177 | 1.020 | 1.051 | 1.014 | 1.001 | 0.976 | 0.963 | $\textit{{\color[rgb]{0,0,1} 0.930}}^{\,*}$ | $\textbf{{\color[rgb]{0,0,1} 0.912}}^{\,**}$ | $\textbf{{\color[rgb]{0,0,1} 0.902}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.915}}^{\,**}$ | 0.923
D. Disaggregation: groups (IBGE)
AR | 2.731 | 1.296 | 1.048 | 1.063 | 1.054 | 1.032 | 1.067 | 1.087 | 1.118 | 1.145 | 1.105 | 1.095 | 1.067
Augmented AR | 1.004 | 1.046 | 1.042 | 1.056 | 1.088 | 1.046 | 1.067 | 1.065 | 1.069 | 1.105 | 1.134 | 1.180 | 1.028
Ridge | 1.656 | 1.288 | 1.044 | 1.032 | 1.016 | 1.010 | 0.986 | 0.989 | 0.972 | 0.983 | 0.989 | 0.999 | 1.005
adaLASSO | 1.223 | 1.090 | 1.026 | 1.013 | 1.003 | 0.994 | 1.019 | 0.989 | 0.972 | 1.004 | 0.988 | 1.000 | 0.954
Factor | 1.219 | 1.075 | 1.034 | 1.031 | 1.035 | 1.021 | 1.024 | 0.967 | 0.974 | 1.021 | 1.000 | 0.990 | 1.005
FarmPredict | 1.334 | 1.089 | 1.025 | 1.049 | 1.040 | 1.016 | 1.023 | 0.991 | 0.971 | 1.029 | 0.997 | 0.998 | 1.020
Target Factor | 1.268 | 1.082 | 1.068 | 1.142 | 1.047 | 0.997 | 0.976 | 0.961 | 1.003 | 0.970 | 1.026 | 1.092 | 0.977
CSR | 2.146 | 1.144 | 1.048 | 1.047 | 1.002 | 0.980 | $\textit{{\color[rgb]{0,0,1} 0.940}}^{\,*}$ | $\textbf{{\color[rgb]{0,0,1} 0.926}}^{\,*}$ | 0.975 | 0.981 | 0.981 | 0.985 | $\textbf{{\color[rgb]{0,0,1} 0.900}}^{\,*}$
Random Forest | 2.096 | 1.217 | 1.026 | 1.047 | 1.009 | 0.998 | 0.971 | 0.953 | 0.944 | $\textit{{\color[rgb]{0,0,1} 0.931}}^{\,*}$ | $\textit{{\color[rgb]{0,0,1} 0.920}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.921}}^{\,*}$ | 0.955
E. Disaggregation: subgroups (IBGE)
AR | 3.111 | 1.502 | 1.186 | 1.212 | 1.244 | 1.184 | 1.212 | 1.253 | 1.264 | 1.316 | 1.275 | 1.362 | 1.318
Augmented AR | 1.197 | 1.260 | 1.290 | 1.288 | 1.290 | 1.191 | 1.164 | 1.212 | 1.239 | 1.310 | 1.314 | 1.440 | 1.208
Ridge | 3.100 | 1.308 | 1.058 | 1.045 | 1.023 | 1.026 | 1.008 | 1.002 | 1.000 | 0.993 | 0.995 | 1.016 | 1.068
adaLASSO | 1.380 | 1.122 | 1.096 | 1.056 | 1.030 | 1.010 | 0.990 | 0.990 | 0.983 | 1.011 | 1.049 | 1.039 | 1.005
Factor | 1.364 | 1.147 | 1.068 | 1.050 | 1.039 | 1.029 | 1.009 | 0.985 | 0.996 | 1.027 | 1.040 | 1.005 | 1.034
FarmPredict | 1.384 | 1.149 | 1.047 | 1.040 | 1.028 | 1.008 | 1.010 | 0.980 | 0.982 | 1.033 | 1.060 | 1.042 | 1.036
Target Factor | 1.230 | 1.059 | 1.145 | 1.126 | 1.117 | 1.059 | 0.976 | 0.937 | 1.028 | 0.979 | 1.051 | 1.116 | 1.021
CSR | 2.222 | 1.210 | 1.076 | 1.067 | 1.027 | 1.028 | 0.977 | 0.955 | 0.939 | 0.987 | 1.034 | 1.030 | 0.974
Random Forest | 2.106 | 1.232 | 1.032 | 1.063 | 1.021 | 1.022 | 0.990 | 0.962 | 0.949 | $\textit{{\color[rgb]{0,0,1} 0.925}}^{\,*}$ | $\textit{{\color[rgb]{0,0,1} 0.917}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.921}}^{\,*}$ | 0.974
F. Model combinations for disaggregates
Aggreg. Comb. | 1.201 | 0.989 | $\textbf{{\color[rgb]{0,0,1} 0.952}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.972}}^{\,*}$ | 0.982 | 0.969 | $\textit{{\color[rgb]{0,0,1} 0.942}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.934}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.935}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.939}}^{\,**}$ | 0.971 | 0.986 | $\textit{{\color[rgb]{0,0,1} 0.935}}^{\,**}$
BCB Comb. | 1.243 | 1.014 | 0.969 | 0.993 | 0.997 | 0.977 | $0.945^{\,*}$ | $0.954^{\,*}$ | $0.950^{\,*}$ | $0.952^{\,*}$ | 0.975 | 0.986 | 0.950
Groups Comb. | 1.401 | 1.068 | 0.976 | 1.001 | 0.988 | 0.969 | 0.970 | 0.954 | 0.959 | 0.982 | 0.978 | 0.995 | 0.961
Subgroups Comb. | 1.583 | 1.129 | 1.035 | 1.045 | 1.031 | 1.007 | 0.981 | 0.966 | 0.985 | 1.004 | 1.026 | 1.046 | 1.029

Notes: ∗∗∗, ∗∗, and ∗ indicate that for a specific forecast horizon, a model
$m$ performed statistically better than the median of the available Focus at
1, 5, and 10% significance levels in a one-tailed Diebold-Mariano test with
$\operatorname{\mathbb{H}}_{0}:\text{MSE}\big{(}\widehat{\pi}_{t+h\,|\,t}^{m}\big{)}=\text{MSE}\big{(}\pi_{t+h\,|\,t}^{\text{Focus}}\big{)}\;\textit{
versus
}\operatorname{\mathbb{H}}_{1}:\text{MSE}\big{(}\widehat{\pi}_{t+h\,|\,t}^{m}\big{)}<\text{MSE}\big{(}\pi_{t+h\,|\,t}^{\text{Focus}}\big{)}$.
The value highlighted in bold blue indicates the best model for each horizon
in terms of RMSE ratio with respect to ex-post Focus, and the values in blue
italics indicate the second and third best models.

Panels B to E of Table 1 show the results for each model considering different
levels of disaggregation: aggregate inflation, disaggregations from the
Central Bank of Brazil (BCB), and disaggregations into IBGE groups and
subgroups, respectively. Perhaps not surprisingly, it is hard to outperform
the Focus survey in nowcasting. Exceptions are due to models that forecast
aggregate inflation directly. However, such models perform better only than
the available Focus. Considering the whole period, no alternative beats the
ex-post Focus, which delivers almost 7% RMSE reduction compared to the
available survey. However, it is appreciable that some models are competitive
with the ex-post Focus. Specialists who report their expectations to the BCB
often have access to information unavailable to econometricians, such as
private data. Since models do not have this additional information and other
advantages, such as including personal judgments, as pointed out by Faust and
Wright (2013), their ability to outperform available expectations and get
closer to ex-post survey-based expectations is a great result. We note that
models forecasting disaggregates do not deliver good performance for
nowcasting. Lastly, the combinations of models in each level of
disaggregation, whose results are shown in Panel F, also do not generate
forecasts better.

For other horizons, the contribution of the models becomes more effective.
Despite the challenge of surpassing survey-based expectations for short-term
horizons such as $h=1$ and $h=2$, several models for aggregate inflation
(Panel B) achieve good results for these horizons. Like occurred for $h=0$,
the hybrid Phillips curve, adaLASSO, factor model, FarmPredict, and,
additionally, the complete subset regression (CSR), deliver the best forecast
performances for one and two months ahead. All are statistically superior to
the available Focus according to the Diebold-Mariano (DM) test considering at
least the more slack significance level (i.e., 10%). Furthermore, these models
also numerically outperform the ex-post Focus. On the other hand, the adaLASSO
using BCB disaggregation (Panel C) is the only model employing any
disaggregation among the best models. However, this model is not statistically
superior to the available Focus by the DM test. Finally, regarding these
shorter horizons, it is worth highlighting the performance of the average
forecast of the models for aggregate inflation, which achieves the highest
accuracy for $h=2$ by presenting a statistically significant reduction of
almost 5% in RMSE.

Models considering some disaggregation for the inflation yield better results
starting from the 4-month horizon. The adaLASSO, factor model, and
FarmPredict, all using the BCB disaggregation, perform well for forecast
horizons ranging from fourth to seventh months. These models are statistically
superior to available or ex-post Focus at various periods. Regarding the use
of disaggregated inflation data in groups from the IBGE, it is worth
mentioning the good performance of the CSR, which achieves the best result
among all the options for $h=7$. Another highlight is the combination of
forecasts generated by models that directly forecast the aggregate inflation,
which achieves a statistically significant reduction of 6% in RMSE from 6 to 9
months ahead. For $h\geqslant 8$, there is broad dominance of the random
forest (RF), whether using aggregate inflation or some disaggregation.
Frequently, for these more distant horizons, the RF registers a statistically
significant reduction in RMSE ranging from 7% to 10% in comparison to the
survey-based expectations. This result highlights that the RF, employing IBGE
group disaggregation, achieves the best performance among all competitors for
inflation accumulated over 12 months (see last column of Table 1), closely
followed by the adaLASSO using BCB disaggregation, which achieves a similar
RMSE reduction.

##### Remarks.

Considering the forecast performance of various models from January 2014 to
June 2022, we observe that different approaches are more effective at
different times. In the short term, machine learning models that deal directly
with aggregate inflation perform better, whereas for intermediate horizons of
4 to 7 months, considering the BCB disaggregation lead to significant
benefits. For the period between 6 and 9 months ahead, the average of
forecasts obtained from models that used only aggregate inflation also perform
well. Finally, for longer horizons of 8 months or more, regardless of the
approach, the RF delivers the best forecast performances. While Garcia,
Medeiros, and Vasconcelos (2017) points to the superiority of the CSR in
several horizons, we only verify the prevalence of the CSR for $h=1$ and other
isolated good performances. The RF’s performance in predicting inflation had
already been pointed out by Medeiros, Vasconcelos, Veiga, and Zilberman (2021)
when analyzing the case of the United States and highlighting the benefits of
this method for dealing with non-linearities. The advent of the COVID-19
pandemic in Brazil changes the price dynamics considerably from 2020 onwards.
Because of that, in what follows, we divide our analysis into two sub-periods:
(i) before the pandemic, from January 2014 to February 2020, and (ii) after
the pandemic, from March 2020 onwards.

###  5.2 Forecasts before and after of COVID-19 pandemic

Table 2 shows that the sub-period between January 2014 and February 2020 is
quite challenging for model-based forecasts. Almost no RMSE ratios are below
1, with exceptions mainly in the short term. Nevertheless, no model is able to
beat the ex-post Focus or be statistically superior to the available Focus for
nowcasting. For $h=1$, only the factor model and FarmPredict are statistically
superior to the available Focus at the 10% significance level, with these two
tying with the predictive performance of the ex-post Focus. For the 3-month
forecast, the hybrid Phillips curve for aggregate inflation is subtly superior
to the Focus in numerical terms but without statistical significance. For the
other horizons, no model performs better than the survey-based expectations.
There are some potential explanations for this poor performance of the models.
First, since we are analyzing the first sub-period, a small sample may have
affected the estimates, contributing to the models’ poor forecast performance.
Second, the instabilities in the Brazilian economy in 2014 and 2015 that
resulted in a sharp increase in inflation in 2015, as well as the rapid
disinflation that occurred from the second half of 2016, are challenging
events to anticipate, especially without extensive historical data.
Conversely, from 2017 until the begging of the COVID-19 pandemic, Brazilian
inflation remained reasonably controlled and close to the inflation target,
leaving limited opportunities for models to enhance survey-based expectations.
These dynamics of the Brazilian inflation can be observed from Figure 3 later
on.

Table 2: Out-of-sample RMSE with respect to the available Focus: Jan/2014 to
Feb/2020

Estimator/Model | $h=0\quad$ | $h=1\quad$ | $h=2\quad$ | $h=3\quad$ | $h=4\quad$ | $h=5\quad$ | $h=6\quad$ | $h=7\quad$ | $h=8\quad$ | $h=9\quad$ | $h=10\;\,$ | $h=11\;\,$ | $\Sigma\,12m$
---|---|---|---|---|---|---|---|---|---|---|---|---|---
A. Survey
Focus (available) | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000
Focus (ex-post) | $\textbf{{\color[rgb]{0,0,1} 0.932}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.969}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.995}}^{\,**}$ | 1.001 | 0.999 | 1.001 | 0.999 | 1.000 | 1.000 | 1.000 | 0.999 | 1.002 | $\textbf{{\color[rgb]{0,0,1} 0.996}}^{\,***}$
B. Aggregate inflation
RW | 3.088 | 1.752 | 1.428 | 1.474 | 1.574 | 1.547 | 1.516 | 1.427 | 1.260 | 1.240 | 1.307 | 1.382 | 2.114
Historical Mean | 3.309 | 1.492 | 1.246 | 1.208 | 1.184 | 1.173 | 1.155 | 1.146 | 1.133 | 1.125 | 1.127 | 1.134 | 1.422
AR | 2.781 | 1.466 | 1.225 | 1.240 | 1.266 | 1.244 | 1.172 | 1.122 | 1.093 | 1.098 | 1.121 | 1.155 | 1.339
HNKPC | 0.966 | 1.008 | 1.022 | 0.994 | 1.083 | 1.087 | 1.061 | 1.043 | 1.046 | 1.050 | 1.072 | 1.079 | 1.089
Augmented AR | 1.015 | 1.067 | 1.081 | 1.090 | 1.114 | 1.101 | 1.082 | 1.076 | 1.068 | 1.086 | 1.117 | 1.126 | 1.161
adaLASSO | 0.990 | 0.979 | 1.009 | 1.052 | 1.031 | 1.074 | 1.086 | 1.084 | 1.134 | 1.136 | 1.176 | 1.097 | 1.136
Factor | 0.990 | $\textit{{\color[rgb]{0,0,1} 0.970}}^{\,*}$ | 1.001 | 1.016 | 1.056 | 1.055 | 1.056 | 1.043 | 1.106 | 1.121 | 1.113 | 1.115 | 1.109
FarmPredict | 0.990 | $\textit{{\color[rgb]{0,0,1} 0.970}}^{\,*}$ | 1.003 | 1.024 | 1.065 | 1.040 | 1.062 | 1.094 | 1.113 | 1.129 | 1.105 | 1.163 | 1.102
Target Factor | 1.499 | 1.225 | 1.122 | 1.338 | 1.334 | 1.215 | 1.110 | 1.223 | 1.212 | 1.231 | 1.171 | 1.118 | 1.333
CSR | 0.968 | 1.011 | 1.035 | 1.081 | 1.139 | 1.104 | 1.086 | 1.063 | 1.056 | 1.047 | 1.043 | 1.054 | 1.113
Random Forest | 1.918 | 1.276 | 1.156 | 1.151 | 1.137 | 1.144 | 1.130 | 1.130 | 1.101 | 1.113 | 1.110 | 1.127 | 1.319
C. Disaggregation: tradable, nontradable and monitored prices (BCB)
AR | 2.943 | 1.535 | 1.268 | 1.275 | 1.304 | 1.318 | 1.241 | 1.261 | 1.150 | 1.086 | 1.079 | 1.077 | 1.519
Augmented AR | 1.049 | 1.120 | 1.131 | 1.150 | 1.182 | 1.189 | 1.164 | 1.186 | 1.137 | 1.163 | 1.189 | 1.153 | 1.335
Ridge | 1.100 | 1.190 | 1.134 | 1.129 | 1.167 | 1.242 | 1.125 | 1.111 | 1.088 | 1.069 | 1.144 | 1.060 | 1.363
adaLASSO | 1.225 | 1.098 | 1.060 | 1.092 | 1.112 | 1.049 | 1.064 | 1.069 | 1.110 | 1.095 | 1.106 | 1.062 | 1.168
Factor | 1.094 | 1.098 | 1.120 | 1.142 | 1.142 | 1.082 | 1.075 | 1.074 | 1.089 | 1.084 | 1.098 | 1.101 | 1.178
FarmPredict | 1.226 | 1.118 | 1.095 | 1.116 | 1.110 | 1.072 | 1.072 | 1.050 | 1.092 | 1.107 | 1.101 | 1.085 | 1.180
Target Factor | 1.569 | 1.183 | 1.078 | 1.221 | 1.372 | 1.260 | 1.127 | 1.215 | 1.123 | 1.239 | 1.175 | 1.118 | 1.309
CSR | 2.364 | 1.401 | 1.221 | 1.188 | 1.196 | 1.162 | 1.168 | 1.184 | 1.133 | 1.123 | 1.153 | 1.105 | 1.362
Random Forest | 2.223 | 1.322 | 1.161 | 1.167 | 1.163 | 1.182 | 1.164 | 1.161 | 1.131 | 1.107 | 1.112 | 1.134 | 1.380
D. Disaggregation: groups (IBGE)
AR | 3.236 | 1.659 | 1.301 | 1.319 | 1.272 | 1.199 | 1.176 | 1.221 | 1.236 | 1.268 | 1.237 | 1.314 | 1.465
Augmented AR | 1.084 | 1.305 | 1.270 | 1.263 | 1.276 | 1.238 | 1.199 | 1.195 | 1.177 | 1.261 | 1.269 | 1.346 | 1.380
Ridge | 2.043 | 1.443 | 1.205 | 1.171 | 1.149 | 1.136 | 1.111 | 1.107 | 1.084 | 1.098 | 1.106 | 1.116 | 1.329
adaLASSO | 1.361 | 1.273 | 1.159 | 1.146 | 1.128 | 1.110 | 1.154 | 1.155 | 1.163 | 1.186 | 1.148 | 1.146 | 1.302
Factor | 1.411 | 1.270 | 1.164 | 1.163 | 1.157 | 1.157 | 1.127 | 1.105 | 1.105 | 1.114 | 1.109 | 1.119 | 1.289
FarmPredict | 1.510 | 1.226 | 1.148 | 1.174 | 1.181 | 1.138 | 1.108 | 1.113 | 1.089 | 1.139 | 1.128 | 1.149 | 1.322
Target Factor | 1.553 | 1.323 | 1.227 | 1.315 | 1.215 | 1.172 | 1.166 | 1.181 | 1.244 | 1.167 | 1.210 | 1.185 | 1.358
CSR | 2.410 | 1.434 | 1.318 | 1.285 | 1.231 | 1.159 | 1.083 | 1.074 | 1.171 | 1.148 | 1.138 | 1.111 | 1.248
Random Forest | 2.282 | 1.342 | 1.174 | 1.216 | 1.185 | 1.170 | 1.154 | 1.170 | 1.167 | 1.146 | 1.120 | 1.127 | 1.409
E. Disaggregation: subgroups (IBGE)
AR | 3.467 | 1.745 | 1.461 | 1.503 | 1.503 | 1.464 | 1.448 | 1.538 | 1.510 | 1.501 | 1.453 | 1.665 | 1.788
Augmented AR | 1.345 | 1.529 | 1.547 | 1.547 | 1.545 | 1.496 | 1.418 | 1.462 | 1.498 | 1.494 | 1.476 | 1.745 | 1.634
Ridge | 3.208 | 1.448 | 1.214 | 1.185 | 1.151 | 1.142 | 1.124 | 1.107 | 1.108 | 1.111 | 1.110 | 1.118 | 1.390
adaLASSO | 1.533 | 1.261 | 1.264 | 1.174 | 1.141 | 1.117 | 1.105 | 1.166 | 1.149 | 1.150 | 1.200 | 1.166 | 1.308
Factor | 1.521 | 1.266 | 1.180 | 1.149 | 1.156 | 1.133 | 1.108 | 1.106 | 1.104 | 1.110 | 1.137 | 1.114 | 1.280
FarmPredict | 1.541 | 1.273 | 1.136 | 1.148 | 1.146 | 1.121 | 1.117 | 1.098 | 1.081 | 1.143 | 1.176 | 1.173 | 1.302
Target Factor | 1.450 | 1.296 | 1.337 | 1.278 | 1.280 | 1.184 | 1.141 | 1.153 | 1.255 | 1.171 | 1.218 | 1.244 | 1.407
CSR | 2.457 | 1.394 | 1.319 | 1.244 | 1.201 | 1.155 | 1.096 | 1.107 | 1.104 | 1.138 | 1.177 | 1.119 | 1.253
Random Forest | 2.325 | 1.360 | 1.180 | 1.224 | 1.194 | 1.199 | 1.182 | 1.168 | 1.150 | 1.117 | 1.106 | 1.117 | 1.407
F. Model combinations for disaggregates
Aggreg. Comb. | 1.273 | 1.077 | 1.024 | 1.042 | 1.076 | 1.059 | 1.048 | 1.046 | 1.050 | 1.058 | 1.075 | 1.083 | 1.142
BCB Comb. | 1.393 | 1.168 | 1.097 | 1.119 | 1.138 | 1.122 | 1.096 | 1.107 | 1.084 | 1.086 | 1.093 | 1.066 | 1.275
Groups Comb. | 1.610 | 1.271 | 1.142 | 1.158 | 1.133 | 1.100 | 1.083 | 1.090 | 1.104 | 1.117 | 1.107 | 1.126 | 1.290
Subgroups Comb. | 1.739 | 1.290 | 1.187 | 1.180 | 1.163 | 1.138 | 1.105 | 1.118 | 1.133 | 1.130 | 1.143 | 1.172 | 1.341

Notes: see Table 1.

Since the COVID-19 pandemic, most models perform statistically better than the
Focus survey, as seen in Table 3. Models that look directly at aggregate
inflation or use some inflation disaggregation tend to perform very well at
all horizons, including nowcasting. Specifically, the adaLASSO, factor model,
and FarmPredict working directly with the aggregate inflation achieve RMSE 10%
lower than the RMSE of the available Focus and smaller RMSE than the ex-post
Focus, something challenging to imagine before the pandemic. Meanwhile,
augmented AR and ridge, both employing BCB disaggregation, also perform well.
One month ahead, even some models employing the highest level of
disaggregation (i.e., subgroups) deliver good results. From the results in
this second sub-period, we understand the good performance of the RF for the
entire period. Considering aggregate inflation, the method already registers
the best performances from $h=3$, with similar results when using any
disaggregation. Frequently, the RF can reduce the RMSE of the available and
ex-post Focus by up to 30% for longer horizons, regardless of whether
considering aggregate inflation or some disaggregation. For 12-month
accumulated inflation, the RF obtains the best performance when using the BCB
disaggregation: a 35% reduction compared to the RMSE of the main benchmarks.
Finally, regarding model combinations, each is statistically superior to Focus
for all $h\geqslant 1$, often at a 1% significance level. However, the
combinations do not beat some individual models with good predictive
performance in the sub-period.

Table 3: Out-of-sample RMSE with respect to the available Focus: Mar/2020 to
Jun/2022

Estimator/Model | $h=0\quad$ | $h=1\quad$ | $h=2\quad$ | $h=3\quad$ | $h=4\quad$ | $h=5\quad$ | $h=6\quad$ | $h=7\quad$ | $h=8\quad$ | $h=9\quad$ | $h=10\;\,$ | $h=11\;\,$ | $\Sigma\,12m$
---|---|---|---|---|---|---|---|---|---|---|---|---|---
A. Survey
Focus (available) | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000
Focus (ex-post) | $0.934^{\,**}$ | $0.975^{\,***}$ | $0.991^{\,***}$ | 1.001 | 1.000 | 0.999 | 1.001 | 0.999 | 0.999 | 1.000 | 1.002 | 1.001 | 1.000
B. Aggregate inflation
RW | 2.443 | 1.189 | 1.023 | 1.056 | 1.003 | 1.024 | 0.983 | 0.965 | 0.939 | 0.908 | 0.920 | 0.920 | 1.128
Historical Mean | 2.915 | 1.203 | 0.948 | $0.921^{\,**}$ | $0.906^{\,**}$ | $0.888^{\,***}$ | $0.868^{\,***}$ | $0.862^{\,***}$ | $0.863^{\,***}$ | $0.862^{\,***}$ | $0.860^{\,***}$ | $0.857^{\,***}$ | $0.835^{\,***}$
AR | 2.264 | 1.060 | $0.904^{\,*}$ | $0.938^{\,*}$ | $0.937^{\,*}$ | $0.910^{\,**}$ | $0.871^{\,***}$ | $0.827^{\,***}$ | $0.807^{\,***}$ | $0.803^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.828}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.846}}^{\,***}$ | $0.799^{\,***}$
HNKPC | $0.927^{\,*}$ | $0.913^{\,***}$ | $0.933^{\,***}$ | 0.971 | 0.999 | 0.986 | $0.917^{\,***}$ | $0.911^{\,**}$ | $0.896^{\,***}$ | $0.913^{\,***}$ | $0.940^{\,***}$ | $0.976^{\,*}$ | $0.938^{\,***}$
Augmented AR | $0.924^{\,*}$ | $0.904^{\,**}$ | $0.915^{\,**}$ | 0.951 | $0.949^{\,*}$ | $0.916^{\,**}$ | $0.868^{\,***}$ | $0.834^{\,***}$ | $0.825^{\,***}$ | $0.856^{\,***}$ | $0.889^{\,***}$ | $0.927^{\,**}$ | $0.854^{\,***}$
adaLASSO | $\textit{{\color[rgb]{0,0,1} 0.896}}^{\,**}$ | $0.922^{\,**}$ | $0.954^{\,***}$ | $0.948^{\,***}$ | $0.935^{\,***}$ | $0.921^{\,***}$ | $0.889^{\,***}$ | $0.890^{\,***}$ | $0.868^{\,***}$ | $0.893^{\,***}$ | $0.933^{\,***}$ | $0.908^{\,***}$ | $0.879^{\,***}$
Factor | $\textbf{{\color[rgb]{0,0,1} 0.894}}^{\,**}$ | $0.896^{\,***}$ | $0.939^{\,***}$ | $0.923^{\,***}$ | $0.907^{\,***}$ | $0.921^{\,***}$ | $0.938^{\,***}$ | $0.943^{\,***}$ | $0.944^{\,***}$ | $0.931^{\,***}$ | 1.005 | 0.990 | $0.935^{\,***}$
FarmPredict | $\textit{{\color[rgb]{0,0,1} 0.896}}^{\,**}$ | $0.918^{\,***}$ | $0.929^{\,***}$ | $0.958^{\,**}$ | $0.947^{\,**}$ | 0.971 | $0.959^{\,**}$ | $0.964^{\,**}$ | $0.947^{\,**}$ | $0.953^{\,**}$ | $0.965^{\,*}$ | $0.962^{\,*}$ | $0.956^{\,**}$
Target Factor | 1.018 | 1.043 | 0.986 | 0.998 | 0.934 | 0.948 | $\textit{{\color[rgb]{0,0,1} 0.789}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.778}}^{\,***}$ | $0.788^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.740}}^{\,**}$ | $0.889^{\,*}$ | 1.089 | $0.772^{\,***}$
CSR | 0.954 | $0.851^{\,***}$ | $0.904^{\,***}$ | $0.903^{\,**}$ | $0.925^{\,**}$ | $0.909^{\,**}$ | $0.875^{\,***}$ | $0.840^{\,***}$ | $0.845^{\,***}$ | $0.917^{\,**}$ | 1.041 | 1.083 | $0.851^{\,***}$
Random Forest | 1.370 | 0.951 | $0.916^{\,*}$ | $0.896^{\,***}$ | $0.877^{\,***}$ | $0.855^{\,***}$ | $0.815^{\,***}$ | $0.794^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.761}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.740}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.723}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.710}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.689}}^{\,***}$
C. Disaggregation: tradable, nontradable and monitored prices (BCB)
AR | 2.161 | 0.931 | $\textit{{\color[rgb]{0,0,1} 0.831}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.861}}^{\,**}$ | $0.895^{\,*}$ | $0.876^{\,**}$ | $0.815^{\,***}$ | $0.841^{\,***}$ | $0.853^{\,***}$ | $0.910^{\,*}$ | 0.985 | 1.006 | $0.779^{\,***}$
Augmented AR | $\textit{{\color[rgb]{0,0,1} 0.903}}^{\,*}$ | $\textit{{\color[rgb]{0,0,1} 0.841}}^{\,**}$ | $0.914^{\,**}$ | 0.991 | 1.024 | 0.977 | $0.883^{\,***}$ | $0.863^{\,***}$ | $0.849^{\,***}$ | $0.865^{\,***}$ | 0.938 | 1.011 | $0.904^{\,***}$
Ridge | $0.930^{\,*}$ | $0.842^{\,**}$ | $0.903^{\,**}$ | $0.929^{\,**}$ | $0.944^{\,**}$ | $0.950^{\,*}$ | $0.898^{\,***}$ | $0.870^{\,***}$ | $0.871^{\,***}$ | $0.870^{\,***}$ | $0.904^{\,***}$ | $0.919^{\,***}$ | $0.859^{\,***}$
adaLASSO | 0.959 | $0.907^{\,*}$ | $0.895^{\,***}$ | $0.866^{\,***}$ | $0.864^{\,***}$ | $0.867^{\,***}$ | $0.881^{\,***}$ | $0.868^{\,***}$ | $0.869^{\,***}$ | $0.854^{\,***}$ | $0.859^{\,***}$ | $0.873^{\,***}$ | $0.769^{\,***}$
Factor | 0.948 | $0.886^{\,***}$ | $0.884^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.861}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.832}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.808}}^{\,***}$ | $0.829^{\,***}$ | $0.901^{\,***}$ | $0.928^{\,***}$ | $0.946^{\,***}$ | $0.937^{\,***}$ | $0.938^{\,***}$ | $0.827^{\,***}$
FarmPredict | 1.024 | $0.940^{\,**}$ | $0.928^{\,***}$ | $0.867^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.849}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.838}}^{\,***}$ | $0.863^{\,***}$ | $0.934^{\,***}$ | $0.932^{\,***}$ | $0.929^{\,***}$ | $0.933^{\,***}$ | $0.916^{\,***}$ | $0.858^{\,***}$
Target Factor | 1.046 | 0.931 | $0.893^{\,**}$ | 0.982 | 0.910 | 0.924 | $\textit{{\color[rgb]{0,0,1} 0.784}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.727}}^{\,***}$ | $0.827^{\,***}$ | $0.754^{\,***}$ | $0.881^{\,*}$ | 1.046 | $0.729^{\,***}$
CSR | 1.973 | 0.954 | $\textit{{\color[rgb]{0,0,1} 0.834}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.864}}^{\,**}$ | $0.860^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.827}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.769}}^{\,***}$ | $0.796^{\,***}$ | $0.808^{\,***}$ | $0.831^{\,***}$ | $0.912^{\,**}$ | 1.011 | $\textit{{\color[rgb]{0,0,1} 0.719}}^{\,***}$
Random Forest | 1.600 | 1.042 | $0.902^{\,*}$ | 0.955 | $0.886^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.845}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.814}}^{\,***}$ | $0.790^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.748}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.733}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.707}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.716}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.648}}^{\,***}$
D. Disaggregation: groups (IBGE)
AR | 2.118 | 0.888 | $\textit{{\color[rgb]{0,0,1} 0.814}}^{\,*}$ | $\textbf{{\color[rgb]{0,0,1} 0.825}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.856}}^{\,**}$ | $0.890^{\,**}$ | 0.981 | 0.979 | 1.022 | 1.043 | 0.995 | $0.903^{\,**}$ | $0.850^{\,**}$
Augmented AR | 0.918 | $\textbf{{\color[rgb]{0,0,1} 0.767}}^{\,**}$ | $0.836^{\,**}$ | $0.871^{\,*}$ | $0.924^{\,*}$ | $0.878^{\,**}$ | 0.960 | 0.961 | 0.983 | 0.973 | 1.024 | 1.043 | $0.841^{\,***}$
Ridge | 1.153 | 1.143 | $0.907^{\,**}$ | $0.916^{\,**}$ | $0.904^{\,**}$ | $0.907^{\,***}$ | $0.884^{\,***}$ | $0.894^{\,***}$ | $0.881^{\,***}$ | $0.887^{\,***}$ | $0.893^{\,***}$ | $0.905^{\,***}$ | $0.835^{\,***}$
adaLASSO | 1.070 | $0.910^{\,*}$ | $0.915^{\,**}$ | $0.901^{\,**}$ | $0.898^{\,***}$ | $0.900^{\,***}$ | $0.909^{\,**}$ | $0.849^{\,***}$ | $0.803^{\,***}$ | $0.844^{\,***}$ | $0.851^{\,***}$ | $0.879^{\,***}$ | $0.767^{\,***}$
Factor | 0.993 | $0.880^{\,**}$ | $0.926^{\,**}$ | $0.922^{\,**}$ | $0.934^{\,**}$ | $0.909^{\,***}$ | $0.942^{\,**}$ | $0.854^{\,***}$ | $0.866^{\,***}$ | $0.946^{\,**}$ | $0.911^{\,***}$ | $0.885^{\,***}$ | $0.861^{\,***}$
FarmPredict | 1.134 | 0.960 | $0.923^{\,**}$ | $0.946^{\,*}$ | $0.922^{\,**}$ | $0.916^{\,**}$ | $0.957^{\,*}$ | $0.893^{\,***}$ | $0.874^{\,***}$ | $0.938^{\,**}$ | $0.888^{\,***}$ | $0.871^{\,***}$ | $0.865^{\,***}$
Target Factor | 0.904 | $\textit{{\color[rgb]{0,0,1} 0.831}}^{\,**}$ | 0.934 | 0.995 | $0.901^{\,*}$ | $0.846^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.812}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.765}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.779}}^{\,***}$ | $0.792^{\,***}$ | $0.865^{\,**}$ | 1.019 | $0.768^{\,***}$
CSR | 1.849 | $\textit{{\color[rgb]{0,0,1} 0.831}}^{\,*}$ | $\textbf{{\color[rgb]{0,0,1} 0.792}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.828}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.789}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.825}}^{\,***}$ | $0.823^{\,***}$ | $0.802^{\,***}$ | $0.799^{\,***}$ | $0.834^{\,***}$ | $0.846^{\,***}$ | $0.882^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.710}}^{\,***}$
Random Forest | 1.895 | 1.102 | $0.902^{\,*}$ | $0.902^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.855}}^{\,**}$ | $0.851^{\,***}$ | $0.815^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.760}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.738}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.731}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.737}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.735}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.685}}^{\,***}$
E. Disaggregation: subgroups (IBGE)
AR | 2.715 | 1.264 | 0.931 | 0.939 | 1.008 | 0.927 | 1.009 | 0.999 | 1.047 | 1.158 | 1.126 | 1.089 | 1.067
Augmented AR | 1.030 | 0.982 | 1.060 | 1.056 | 1.061 | 0.905 | 0.939 | 0.995 | 1.006 | 1.153 | 1.180 | 1.168 | 0.980
Ridge | 2.990 | 1.179 | $0.927^{\,*}$ | $0.927^{\,**}$ | $0.915^{\,**}$ | $0.931^{\,**}$ | $0.916^{\,***}$ | $0.920^{\,**}$ | $0.912^{\,**}$ | $0.896^{\,***}$ | $0.901^{\,***}$ | $0.934^{\,**}$ | $0.903^{\,***}$
adaLASSO | 1.210 | 0.992 | 0.954 | 0.960 | $0.938^{\,**}$ | $0.925^{\,**}$ | $0.898^{\,***}$ | $0.841^{\,***}$ | $0.841^{\,***}$ | $0.893^{\,***}$ | $0.922^{\,***}$ | $0.936^{\,***}$ | $0.849^{\,***}$
Factor | 1.189 | 1.037 | 0.977 | 0.971 | $0.943^{\,**}$ | $0.946^{\,**}$ | $0.932^{\,***}$ | $0.887^{\,***}$ | $0.909^{\,***}$ | $0.961^{\,*}$ | $0.962^{\,**}$ | $0.918^{\,***}$ | $0.914^{\,***}$
FarmPredict | 1.209 | 1.034 | 0.975 | 0.951 | $0.930^{\,**}$ | $0.916^{\,**}$ | $0.925^{\,***}$ | $0.886^{\,***}$ | $0.903^{\,***}$ | $0.942^{\,**}$ | $0.965^{\,**}$ | $0.935^{\,***}$ | $0.904^{\,***}$
Target Factor | 0.964 | $\textit{{\color[rgb]{0,0,1} 0.810}}^{\,*}$ | 0.979 | 0.998 | 0.977 | 0.959 | $0.838^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.744}}^{\,***}$ | $0.823^{\,***}$ | $0.807^{\,**}$ | 0.908 | 1.012 | $0.810^{\,***}$
CSR | 1.963 | 1.033 | $0.853^{\,***}$ | $0.914^{\,**}$ | $0.875^{\,***}$ | $0.923^{\,***}$ | $0.882^{\,***}$ | $0.829^{\,***}$ | $0.795^{\,***}$ | $0.857^{\,***}$ | $0.913^{\,***}$ | 0.961 | $0.832^{\,***}$
Random Forest | 1.865 | 1.114 | $0.908^{\,*}$ | $0.926^{\,*}$ | $0.869^{\,**}$ | $0.870^{\,**}$ | $0.825^{\,***}$ | $0.781^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.768}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.750}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.746}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.746}}^{\,***}$ | $0.725^{\,***}$
F. Model combinations for disaggregates
Aggreg. Comb. | 1.127 | $0.909^{\,***}$ | $0.895^{\,***}$ | $0.918^{\,***}$ | $0.906^{\,***}$ | $0.898^{\,***}$ | $0.858^{\,***}$ | $0.845^{\,***}$ | $0.840^{\,***}$ | $0.840^{\,***}$ | $0.886^{\,***}$ | $0.910^{\,***}$ | $0.835^{\,***}$
BCB Comb. | 1.075 | $0.866^{\,***}$ | $0.862^{\,***}$ | $0.888^{\,***}$ | $0.877^{\,***}$ | $0.856^{\,***}$ | $0.820^{\,***}$ | $0.827^{\,***}$ | $0.838^{\,***}$ | $0.839^{\,***}$ | $0.878^{\,***}$ | $0.923^{\,***}$ | $0.777^{\,***}$
Groups Comb. | 1.159 | $0.864^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.833}}^{\,***}$ | $0.866^{\,***}$ | $0.864^{\,***}$ | $0.861^{\,***}$ | $0.880^{\,***}$ | $0.842^{\,***}$ | $0.836^{\,***}$ | $0.868^{\,***}$ | $0.869^{\,***}$ | $0.888^{\,***}$ | $0.786^{\,***}$
Subgroups Comb. | 1.411 | 0.975 | $0.906^{\,**}$ | $0.932^{\,**}$ | $0.921^{\,***}$ | $0.899^{\,***}$ | $0.882^{\,***}$ | $0.840^{\,***}$ | $0.860^{\,***}$ | $0.898^{\,**}$ | $0.929^{\,**}$ | $0.944^{\,**}$ | $0.869^{\,***}$

Notes: see Table 1.

Figure 3 presents the temporal evolution of actual inflation, Focus survey
expectations, and the best aggregate- and disaggregates-based models for each
horizon. Looking at the projections for $h=0$, we partially understand why it
is not easy to outperform the survey in the very-short term. The Focus
consensus is very close to the actual values. Furthermore, as we will see in
Subsection 5.3, available inflation expectations are the primary predictor for
model-based nowcasting. The survey contains much relevant information
unavailable to the econometrician, so we already expect this result. When
analyzing the other horizons ($h\geqslant 1$), we note that it is challenging
for the survey and models to predict peaks and valleys of inflation. Already
at $h=1$, we observe outstanding forecasting errors. One consequence of
COVID-19, which start is highlighted by vertical dashed lines on each plot, is
that the Focus survey initially overestimated inflation and afterward
systematically underestimated one. Despite the challenges of generating
accurate forecasts in such an uncertain period, several models perform better
than expert forecasts for all horizons. A punctual example is the adaLASSO
that, using both aggregates and BCB disaggregations, as well as other models,
achieves a great result in forecasting the peak observed in December 2020 at
$h=1$, a point at which the available inflation expectation is far from the
actual value. Thus, other variables besides the available inflation
expectations are fundamental for the performance of model-based forecasts.

Figure 3: Forecasts by each horizon and 12-month cumulative period

Notes: Black solid lines indicate the actual inflation. Gray dashed lines
indicate the median of the ex-post inflation expectations from the Focus
survey on the last business day of each month. Solid-colored lines indicate
forecasts generated by different models or a combination of models. The
vertical dashed lines separate the period before and after the COVID-19
pandemic.

##### Remarks.

The good performance of the RF is mainly due to its ability to capture the
higher level of future inflation from the second half of 2020. The model
generates forecasts closer to the actual inflation than the Focus
expectations, which systematically underestimate inflation in that period.
Since the pandemic, models for disaggregated inflation tend to provide more
accurate forecasts than models for aggregate inflation, except for nowcasting.
For each $h\geqslant 2$, we note that adaLASSO, factor model, FarmPredict, and
CSR using any disaggregation of inflation deliver forecasts with lower RMSE
than the respective models using aggregate inflation, with a few exceptions
for the CSR using groups and subgroups that do not outperform the CSR using
aggregate inflation. In turn, the RF performs well regardless of the target
variable. These findings underscore the use of models in inflation
forecasting, including the junction between disaggregated analysis and machine
learning techniques, particularly during periods of higher economic
instability, such as a pandemic. Previous studies such as Altug and Çakmaklı
(2016) and Medeiros, Vasconcelos, Veiga, and Zilberman (2021) have also shown
that models perform well during more volatile periods. Next, we will analyze
the forecasts for disaggregates and identify the predictors selected by
adaLASSO and FarmPredict, methods that allow variable selection.

###  5.3 Forecast of disaggregates and variable selection

####  5.3.1 Disaggregation into BCB categories

##### Predictive performance.

Now we consider the predictive performance of the models using different
disaggregations, starting with the disaggregation from the BCB. Since we lack
long time series for survey-based expectations for disaggregated inflation, we
use the AR model as a benchmark. Of all the BCB disaggregations, monitored
prices are the most challenging to forecast since they are subject to many
unexpected changes resulting from government decisions that often do not
freely follow supply and demand movements. According to the results displayed
in Table 4, other models manage to beat the AR only in short or more distant
horizons for this disaggregate (Panel A). In nowcasting, other methods perform
significantly better than the AR, with augmented AR and Ridge standing out by
obtaining more than a 30% reduction in RMSE. For $h=1$, augmented AR achieves
a 10% reduction in RMSE, the only statistically significant at any level. Some
models present minor RMSE for intermediate horizons, but the results are not
statistically significant according to the DM test. For ten and eleven months
ahead, Ridge delivers reductions of 4% and 6% in RMSE, respectively, compared
to the AR, and, specifically for $h=11$, adaLASSO, factor model, and
FarmPredict also statistically outperform the AR, with RMSE reductions ranging
from 3% and 4%. Putting all horizons together, Ridge, adaLASSO, FarmPredict,
and factor model generate more accurate forecasts than the AR by delivering
RMSEs 2% to 4% lower than the AR model, all statistically significant at the
1% level. The good result of the augmented AR model is restricted to the short
term.

Table 4: Out-of-sample RMSE for BCB disaggregate (in terms of RMSE of the AR
model): Jan/2014 to Jun/2022, by disaggregate and horizon

Estimator/Model | $h=0\quad\,$ | $h=1\quad\,$ | $h=2\quad\,$ | $h=3\quad\,$ | $h=4\quad\,$ | $h=5\quad\,$ | $h=6\quad\,$ | $h=7\quad\,$ | $h=8\quad\,$ | $h=9\quad\,$ | $h=10\;\;$ | $h=11\;\;$ | all $h$
---|---|---|---|---|---|---|---|---|---|---|---|---|---
A. Monitored Prices |
AR | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000
Augmented AR | $\textbf{{\color[rgb]{0,0,1} 0.694}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.903}}^{\,***}$ | 1.015 | 1.022 | 1.025 | 1.023 | 1.026 | 1.035 | 1.038 | 1.037 | 1.021 | 1.033 | 0.996
Ridge | $\textit{{\color[rgb]{0,0,1} 0.709}}^{\,***}$ | 0.954 | 0.987 | 0.984 | 0.984 | 0.988 | 1.001 | 0.985 | 0.988 | 0.986 | $\textbf{{\color[rgb]{0,0,1} 0.957}}^{\,**}$ | $\textbf{{\color[rgb]{0,0,1} 0.943}}^{\,**}$ | $\textbf{{\color[rgb]{0,0,1} 0.960}}^{\,***}$
adaLASSO | $0.756^{\,***}$ | 0.960 | 0.986 | 0.988 | 0.987 | 0.987 | 1.004 | 0.989 | 0.996 | 1.004 | 0.971 | $0.962^{\,*}$ | $\textit{{\color[rgb]{0,0,1} 0.969}}^{\,***}$
Factor | $0.734^{\,***}$ | 0.970 | 1.008 | 1.003 | 0.999 | 0.999 | 1.016 | 1.009 | 1.006 | 0.996 | 0.976 | $0.961^{\,*}$ | $0.977^{\,***}$
FarmPredict | $0.774^{\,***}$ | 0.980 | 1.002 | 0.998 | 0.997 | 1.009 | 0.998 | 0.982 | 0.996 | 0.998 | 0.974 | $0.965^{\,*}$ | $0.975^{\,***}$
Target Factor | $0.750^{\,***}$ | 1.033 | 1.045 | 1.082 | 1.063 | 1.079 | 1.086 | 1.149 | 1.143 | 1.097 | 1.073 | 1.080 | 1.063
CSR | 0.974 | 1.002 | 1.022 | 1.034 | 1.061 | 1.053 | 1.034 | 1.046 | 1.066 | 1.057 | 1.021 | 1.027 | 1.034
Random Forest | $0.872^{\,***}$ | 1.020 | 1.039 | 1.060 | 1.058 | 1.076 | 1.098 | 1.068 | 1.061 | 1.033 | 0.967 | 0.956 | 1.027
B. Non-Tradables |
AR | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000
Augmented AR | $\textit{{\color[rgb]{0,0,1} 0.843}}^{\,**}$ | $0.831^{\,***}$ | $0.844^{\,***}$ | $0.820^{\,***}$ | $0.810^{\,***}$ | $0.787^{\,***}$ | $0.829^{\,***}$ | $0.853^{\,**}$ | $0.907^{\,**}$ | 0.963 | 0.985 | 0.975 | $0.869^{\,***}$
Ridge | $\textbf{{\color[rgb]{0,0,1} 0.824}}^{\,***}$ | $0.817^{\,***}$ | $0.830^{\,***}$ | $0.808^{\,***}$ | $0.796^{\,***}$ | $0.780^{\,***}$ | $0.823^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.847}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.900}}^{\,**}$ | 0.944 | 0.957 | 0.950 | $0.854^{\,***}$
adaLASSO | $0.896^{\,*}$ | $\textbf{{\color[rgb]{0,0,1} 0.784}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.778}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.777}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.748}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.733}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.812}}^{\,***}$ | $0.850^{\,**}$ | 0.944 | 0.977 | 0.955 | 0.962 | $\textit{{\color[rgb]{0,0,1} 0.847}}^{\,***}$
Factor | $0.889^{\,**}$ | $0.809^{\,***}$ | $0.806^{\,***}$ | $0.804^{\,***}$ | $0.765^{\,***}$ | $0.774^{\,***}$ | $0.823^{\,***}$ | $0.866^{\,**}$ | 0.951 | 1.006 | 0.968 | 0.950 | $0.864^{\,***}$
FarmPredict | $0.895^{\,*}$ | $\textit{{\color[rgb]{0,0,1} 0.798}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.782}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.768}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.744}}^{\,***}$ | $0.739^{\,***}$ | $0.842^{\,***}$ | $0.855^{\,**}$ | 0.955 | 1.000 | 0.968 | 0.938 | $0.853^{\,***}$
Target Factor | 1.040 | $0.846^{\,**}$ | 0.896 | 1.022 | 0.935 | $0.799^{\,***}$ | $0.885^{\,*}$ | 1.030 | 1.026 | 1.015 | 0.944 | 1.045 | $0.954^{\,**}$
CSR | $0.892^{\,***}$ | $0.864^{\,***}$ | $0.887^{\,***}$ | $0.887^{\,***}$ | $0.867^{\,***}$ | $0.816^{\,***}$ | $0.856^{\,***}$ | $0.875^{\,***}$ | $0.931^{\,*}$ | 0.956 | 0.968 | 1.013 | $0.899^{\,***}$
Random Forest | $0.868^{\,***}$ | $0.855^{\,***}$ | $0.816^{\,***}$ | $0.803^{\,***}$ | $0.778^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.729}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.791}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.805}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.854}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.886}}^{\,**}$ | $\textbf{{\color[rgb]{0,0,1} 0.893}}^{\,**}$ | $\textbf{{\color[rgb]{0,0,1} 0.918}}^{\,*}$ | $\textbf{{\color[rgb]{0,0,1} 0.829}}^{\,***}$
C. Tradables |
AR | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000
Augmented AR | $0.832^{\,**}$ | $0.911^{\,**}$ | 0.995 | 1.070 | 1.082 | 1.051 | 0.998 | $0.948^{\,**}$ | $0.951^{\,*}$ | 0.989 | 1.044 | 1.055 | 1.003
Ridge | $0.810^{\,***}$ | $0.920^{\,**}$ | $0.954^{\,**}$ | 0.982 | $0.960^{\,**}$ | 1.042 | $0.899^{\,***}$ | $0.874^{\,***}$ | $0.917^{\,**}$ | $0.935^{\,**}$ | 1.030 | $0.889^{\,***}$ | $0.940^{\,***}$
adaLASSO | $\textbf{{\color[rgb]{0,0,1} 0.763}}^{\,***}$ | $0.941^{\,*}$ | $0.943^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.940}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.909}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.844}}^{\,***}$ | $0.848^{\,***}$ | $0.861^{\,***}$ | $0.918^{\,**}$ | $0.886^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.912}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.834}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.886}}^{\,***}$
Factor | $0.814^{\,***}$ | $0.928^{\,**}$ | 0.972 | $0.956^{\,*}$ | $0.927^{\,**}$ | $0.860^{\,***}$ | $0.845^{\,***}$ | $0.882^{\,***}$ | $0.932^{\,**}$ | 0.966 | $0.937^{\,*}$ | $0.906^{\,***}$ | $0.913^{\,***}$
FarmPredict | $0.811^{\,***}$ | 0.967 | 0.980 | 0.967 | $0.929^{\,**}$ | $0.872^{\,***}$ | $0.858^{\,***}$ | $0.897^{\,***}$ | $0.940^{\,*}$ | $0.956^{\,*}$ | $0.937^{\,*}$ | $0.899^{\,***}$ | $0.920^{\,***}$
Target Factor | $\textit{{\color[rgb]{0,0,1} 0.792}}^{\,**}$ | $\textbf{{\color[rgb]{0,0,1} 0.886}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.907}}^{\,**}$ | 0.979 | 1.000 | 0.935 | $\textit{{\color[rgb]{0,0,1} 0.821}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.769}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.831}}^{\,***}$ | $0.896^{\,**}$ | 0.990 | $0.926^{\,*}$ | $0.900^{\,***}$
CSR | $0.884^{\,**}$ | 1.045 | 1.079 | 1.003 | $0.917^{\,*}$ | $0.886^{\,***}$ | $0.909^{\,***}$ | $0.884^{\,***}$ | $0.866^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.873}}^{\,***}$ | $0.925^{\,**}$ | $0.932^{\,***}$ | $0.933^{\,***}$
Random Forest | $0.820^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.903}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.906}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.902}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.853}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.824}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.819}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.810}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.836}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.848}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.841}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.810}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.847}}^{\,***}$

Notes: ∗∗∗, ∗∗, and ∗ indicate that for a specific disaggregate and forecast
horizon, a model $m$ performed statistically better than an AR model at 1, 5,
and 10% significance levels in a one-tailed Diebold-Mariano test with
$\operatorname{\mathbb{H}}_{0}:\text{MSE}\big{(}\widehat{\pi}_{i,\,t+h\,|\,t}^{m}\big{)}=\text{MSE}\big{(}\pi_{i,\,t+h\,|\,t}^{\text{AR}}\big{)}\;\textit{
versus
}\operatorname{\mathbb{H}}_{1}:\text{MSE}\big{(}\widehat{\pi}_{i,\,t+h\,|\,t}^{m}\big{)}<\text{MSE}\big{(}\pi_{i,\,t+h\,|\,t}^{\text{AR}}\big{)}$.
The value highlighted in bold blue indicates the best model for each horizon
in terms of RMSE ratio with respect to the AR model, and the values in blue
italics indicate the second and third best models. The average weights of each
disaggregate in IPCA are: monitored prices (25%); non-tradables (41.5%); and
tradables ( 33.5%).

Looking at the other BCB disaggregates, namely non-tradable and tradable
items, we notice that machine learning models deliver better results than the
traditional AR model (Panels B and C of Table 4). For non-tradables, once
again augmented AR and Ridge stand out in nowcasting with RMSE reductions of
18% and 16%, while adaLASSO and FarmPredict achieve the best performances
between one and five months ahead, with RMSE reductions oscillating between
20% and 27%. For all $h\geqslant 5$, the random forest dominates by delivering
the lowest RMSE. Aggregating all horizons, all ML models perform statistically
better than AR for non-tradable items. In turn, the results for tradables are
similar, with the ML methods yielding subtly smaller improvements. Also for
tradables, there is a predominance of the RF: this method obtains the best or
second-best performance for all $h\geqslant 1$, with RMSE reductions ranging
from 10% to 19%. Other methods that stand out are adaLASSO, which obtains the
best result in nowcasting (almost 24% reduction in RMSE), and target factor,
which registers the best performance one, seven, and eight months ahead. By
gathering the forecasts for all periods, the RF obtains an average reduction
of 15% in RMSE compared to the AR model, with adaLASSO coming close behind,
with a reduction of 11% in RMSE. All models, except the augmented AR,
outperform the AR at the 1% significance level. These findings suggest that
models that include more predictors, impose restrictions on parameters, or
assume other functional forms can be more advantageous in inflation
forecasting than traditional time-series models such as the AR model. Lastly,
we note that the improvements due to ML methods in a data-rich environment are
not just observed for the pandemic period, as seen in Tables C1 and C2 in
Appendix C.

##### Variable selection.

To explore potential economic intuitions for the results from aggregate
inflation and BCB disaggregation, we compare what is behind the two approaches
in terms of variable selections by adaLASSO and FarmPredict, as shown in
Figures 4 and 5, respectively. In both Figures, panel A brings the predictors
that each method selected to forecast the aggregate inflation directly.
Meanwhile, panels B, C, and D display the predictors selected to predict price
variation of administrated, non-tradable, and tradable items. To make the
presentation viable, we restricted ourselves to the variables chosen at least
20% and 11.5% of the time in at least one forecast horizon, respectively.
Variables definitions are shown in Table B1 in Appendix B. The prefix “u_” in
some variables in Figure 5 indicates that the variable had the common factors
“discounted” and, therefore, only its idiosyncratic component is left. These
variables are indicated by $\widehat{u}_{j}$ in Equation (3.3).

Figure 4: adaLASSO selection: aggregate inflation and BCB disaggregates (% of
extending windows)

Notes: We cut out variables that do not exceed 20% of selection at least one
forecast horizon. The definitions of the variables are in Table B1.

Figure 5: FarmPredict selection: aggregate inflation and BCB disaggregates (%
of extending windows)

Notes: We cut out variables that do not exceed 11.5% of selection at least one
forecast horizon. The definitions of the variables are in Table B1.

We can summarize the results of the variable selections in the following
topics:

  1. 1.

High variability in the type of selected predictors. The adaLASSO selects all
ten classes of predictors (see Table B1 in Appendix B). Even controlling for
common factors (FarmPredict), each class of predictors still appears. This
result shows the importance of considering a broad set of information.

  2. 2.

Low participation of economic activity variables. Variables related to
economic activity appear little when we control for common factors via
FarmPredict and almost never for adaLASSO. There exists some correlation
between activity variables and monetary base, M1 and M2 money supplies,
variables occasionally select, for example. Beyond that, the information
linked to economic activity variables may be contained in other relevant
variables (e.g., inflation expectations), including the possibility of a non-
linear relationship between these variables. Thus, we must be careful not to
conclude that economic activity variables are irrelevant for forecasting
inflation.

  3. 3.

Available inflation expectations (survey) are frequently picked. adaLASSO and
FarmPredict for aggregate and non-tradable items frequently select the
inflation expectation (expec) at all horizons. For administrated and tradable
items, the selection of the expectation decreases as the horizon increases,
appearing only in the very short term for tradables. We note that the
expectation is about aggregate inflation, so it is reasonable that it is not
relevant to explain some specific disaggregate. Furthermore, due to their
greater share, non-tradables present a more remarkable similarity with
aggregate inflation than the other breakdowns.

  4. 4.

Prices (including commodities) are often chosen. According to the variable
selections, Brazilian inflation indexes and commodities price variations are
relevant to forecast official Brazilian inflation. Various indexes and price
variations carry relevant information to forecast Brazilian inflation. In
addition, due to past inflationary history, Brazil has several monthly indexes
calculated by different organizations that cover different periods (e.g., days
1 to 30, 11 to 10, and 21 to 30). Thus, we must consider this information when
forecasting Brazilian inflation.

  5. 5.

Factors that explain most of the variability of predictors are not always more
relevant to forecasting inflation. Interestingly, the common factor that
explains most of the variability of the predictors (i.e., factor1) is rarely
select to forecast aggregate inflation or any disaggregate. Instead, the
following factors up to the tenth are chosen for various horizons, mainly to
predict non-tradables, lesser extent for aggregate and tradables, and very
little for administrated ones.

  6. 6.

Non-tradables record the richer structure of predictors; monitored items, the
poorer. The good predictability of non-tradables is potentially related to the
larger number of predictors. Note that non-tradables have more predictors than
aggregate inflation itself. This finding underscores the importance of looking
at disaggregates. For example, the February dummy’s relevance for forecasting
inflation only appears when we consider the forecast of non-tradable
inflation. This dummy is crucial because it captures the variation in
education prices, a sector whose contracts are usually updated in January. In
turn, the price variation of monitored items has few predictors, contributing
to this disaggregate being the most challenging for forecasting.

####  5.3.2 Disaggregation into IBGE groups

Now we address the predictive performance for each IBGE group. The
identification of each group, as well as their respective participation in the
IPCA, are available in Table A1 in Appendix A. From Table 5, we note that ML
methods perform statistically better than the AR model and numerically better
than the augmented AR for all components by stacking the horizons. An
exception is the target factor, which does not perform well for some groups.
Furthermore, from Table C3 in Appendix C, which presents detailed results of
each disaggregate by forecast horizon, we notice that there are infrequent
horizons that do not have an ML model performing statistically better than the
benchmark.

Table 5: Out-of-sample RMSE for IBGE groups (in terms of RMSE of the AR
model): Jan/2014 to Jun/2022, by disaggregate, joining all horizons

Estimator/Model | inf.g1 | inf.g2 | inf.g3 | inf.g4 | inf.g5 | inf.g6 | inf.g7 | inf.g8 | inf.g9
---|---|---|---|---|---|---|---|---|---
AR | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000
Augmented AR | 1.007 | $0.977^{\,**}$ | 1.062 | $0.874^{\,***}$ | 1.001 | $\textbf{{\color[rgb]{0,0,1} 0.881}}^{\,***}$ | 1.006 | $0.451^{\,***}$ | 1.066
Ridge | $\textit{{\color[rgb]{0,0,1} 0.886}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.908}}^{\,***}$ | $0.956^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.836}}^{\,***}$ | $0.966^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.889}}^{\,***}$ | $0.917^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.446}}^{\,***}$ | $0.805^{\,***}$
adaLASSO | $0.900^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.913}}^{\,***}$ | $0.905^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.844}}^{\,***}$ | $0.961^{\,***}$ | 0.995 | $0.886^{\,***}$ | $0.457^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.790}}^{\,***}$
Factor | $0.911^{\,***}$ | $0.915^{\,***}$ | $0.900^{\,***}$ | $0.863^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.959}}^{\,***}$ | 0.994 | $\textbf{{\color[rgb]{0,0,1} 0.876}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.450}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.795}}^{\,***}$
FarmPredict | $0.909^{\,***}$ | $0.919^{\,***}$ | $0.912^{\,***}$ | $0.920^{\,***}$ | $0.966^{\,***}$ | 1.015 | $\textit{{\color[rgb]{0,0,1} 0.882}}^{\,***}$ | $0.457^{\,***}$ | $0.798^{\,***}$
Target Factor | $0.932^{\,***}$ | 0.992 | $0.905^{\,***}$ | $0.884^{\,***}$ | 1.026 | $0.909^{\,***}$ | 1.008 | $0.487^{\,***}$ | 1.164
CSR | $0.954^{\,**}$ | $0.949^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.849}}^{\,***}$ | $0.898^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.951}}^{\,***}$ | $0.974^{\,*}$ | $0.927^{\,***}$ | $0.698^{\,***}$ | $0.863^{\,***}$
Random Forest | $\textbf{{\color[rgb]{0,0,1} 0.844}}^{\,***}$ | $0.961^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.845}}^{\,***}$ | $0.866^{\,***}$ | $0.968^{\,***}$ | $0.945^{\,***}$ | $0.931^{\,***}$ | $0.573^{\,***}$ | $0.838^{\,***}$

Notes: see Table 4. For a definition of the groups and their respective
weights in the IPCA, see Table A1 in Appendix A.

Different models perform better for different disaggregates. Education
(inf.g8) is the group most benefited from using other techniques. However,
given the good performance of the augmented AR, we infer that predictive
improvement is mainly due to the inclusion of the February dummy. Except for
augmented AR and target factor, the models also achieve predictive improvement
for communication (inf.g9), including all horizons individually.
Transportation is the group for which the models beat the AR model by stacking
the horizons with the smallest margin (inf.g5). In addition, the ML methods
are not statistically superior to AR in half of the forecast horizons for this
disaggregate. The transportation group comprises public transport fares and
expenses with own vehicle and fuel, mostly items whose prices are administered
by the government, which are difficult to forecast. However, except once again
for augmented AR and target factor, the models deliver a statistically
significant average reduction of at least 3% in RMSE compared to the AR model,
with Ridge’s predictive gain around 10% between 6- and 9-month-ahead. Lastly,
it is worth highlighting the good performance of the RF to forecast the price
variation of foods and beverages (inf.g1) at all horizons.

####  5.3.3 Disaggregation into IBGE subgroups

Lastly, we examine the predictive performance for each IBGE subgroup. The
results stacking all horizons are shown in Table 6, and results for each
horizon are in Table C4 in Appendix C. Descriptions of subgroups are in Table
A1 in Appendix A. Similar to what happens with the disaggregation into groups,
ML models achieve more accurate forecasts in comparison to AR models for each
subgroup, but with no single model emerging as a dominant predictor for
different disaggregates. The reduction of RMSE reaches 71% in the case of
courses, reading, and stationery (inf.sg18), 40% for communication (inf.sg19),
and 35% for household operations (inf.sg7) and personal services (inf.sg16).
RF stout out for delivering the best predictive performances considering all
forecast horizons for food at home (inf.sg1), appliances (inf.sg6), household
operations (inf.sg7), and fabrics (inf.sg10). The Ridge performs well at all
horizons for domestic fuels and energy (inf.sg4) and jewelry (inf.sg10), and
the adaLASSO performs well for communication (inf.sg19) at all horizons as
well. Furthermore, we show outstanding performances for specific horizons:
adaLASSO performs well in the long-term for food away from home (inf.sg2),
target factor in short- and intermediate-term for pharmaceutical and optical
products (inf.sg13), while the RF performs well at short term for that one and
at more distant horizons for the latter.

Table 6: Out-of-sample RMSE for IBGE subgroups (in terms of RMSE of the AR
model): Jan/2014 to Jun/2022, by disaggregate, joining all horizons

Estimator/Model | inf.sg1 | inf.sg2 | inf.sg3 | inf.sg4 | inf.sg5 | inf.sg6 | inf.sg7 | inf.sg8 | inf.sg9 | inf.sg10
---|---|---|---|---|---|---|---|---|---|---
AR | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000
Augmented AR | 1.062 | 1.053 | 1.080 | 1.000 | 1.063 | 1.085 | 1.050 | $0.902^{\,***}$ | 1.040 | 1.106
Ridge | $\textit{{\color[rgb]{0,0,1} 0.742}}^{\,***}$ | $0.798^{\,***}$ | $0.804^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.794}}^{\,***}$ | $0.854^{\,***}$ | $0.827^{\,***}$ | $0.681^{\,***}$ | $0.886^{\,***}$ | $0.832^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.693}}^{\,***}$
adaLASSO | $0.766^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.759}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.781}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.803}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.823}}^{\,***}$ | $0.826^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.677}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.737}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.768}}^{\,***}$ | $0.721^{\,***}$
Factor | $0.751^{\,***}$ | $0.803^{\,***}$ | $0.792^{\,***}$ | $0.805^{\,***}$ | $0.838^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.810}}^{\,***}$ | $0.684^{\,***}$ | $0.759^{\,***}$ | $0.780^{\,***}$ | $0.725^{\,***}$
FarmPredict | $0.757^{\,***}$ | $0.795^{\,***}$ | $0.793^{\,***}$ | $0.810^{\,***}$ | $0.839^{\,***}$ | $0.815^{\,***}$ | $0.687^{\,***}$ | $0.809^{\,***}$ | $0.784^{\,***}$ | $0.728^{\,***}$
Target Factor | $0.786^{\,***}$ | $0.811^{\,***}$ | $0.857^{\,***}$ | 0.954 | $0.858^{\,***}$ | $0.836^{\,***}$ | $0.812^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.731}}^{\,***}$ | $0.802^{\,***}$ | $0.808^{\,***}$
CSR | $0.779^{\,***}$ | $0.796^{\,***}$ | $0.785^{\,***}$ | $0.850^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.801}}^{\,***}$ | $0.819^{\,***}$ | $0.683^{\,***}$ | $0.810^{\,***}$ | $0.791^{\,***}$ | $0.730^{\,***}$
Random Forest | $\textbf{{\color[rgb]{0,0,1} 0.706}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.772}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.770}}^{\,***}$ | $0.858^{\,***}$ | $0.849^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.757}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.650}}^{\,***}$ | $0.759^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.734}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.694}}^{\,***}$
Estimator/Model | inf.sg11 | inf.sg12 | inf.sg13 | inf.sg14 | inf.sg15 | inf.sg16 | inf.sg17 | inf.sg18 | inf.sg19 |
AR | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 |
Augmented AR | 1.147 | 1.037 | $0.889^{\,***}$ | 1.010 | 1.023 | 1.117 | 1.061 | $0.436^{\,***}$ | 1.022 |
Ridge | $0.736^{\,***}$ | $0.874^{\,***}$ | $0.941^{\,**}$ | 0.987 | $0.899^{\,***}$ | $0.786^{\,***}$ | $0.742^{\,***}$ | $0.415^{\,***}$ | $0.613^{\,***}$ |
adaLASSO | $\textit{{\color[rgb]{0,0,1} 0.706}}^{\,***}$ | $0.861^{\,***}$ | $0.827^{\,***}$ | $0.979^{\,*}$ | $0.898^{\,***}$ | $0.713^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.737}}^{\,***}$ | $0.389^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.599}}^{\,***}$ |
Factor | $0.736^{\,***}$ | $0.863^{\,***}$ | $0.892^{\,***}$ | $0.970^{\,**}$ | $0.899^{\,***}$ | $0.719^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.734}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.383}}^{\,***}$ | $0.605^{\,***}$ |
FarmPredict | $0.739^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.861}}^{\,***}$ | $0.877^{\,***}$ | $0.978^{\,*}$ | $\textbf{{\color[rgb]{0,0,1} 0.896}}^{\,***}$ | $0.730^{\,***}$ | $0.738^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.389}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.604}}^{\,***}$ |
Target Factor | $0.774^{\,***}$ | $0.923^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.729}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.958}}^{\,**}$ | $0.924^{\,***}$ | $0.807^{\,***}$ | $0.831^{\,***}$ | $0.400^{\,***}$ | $0.829^{\,***}$ |
CSR | $0.722^{\,***}$ | $0.867^{\,***}$ | $0.848^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.967}}^{\,**}$ | $\textit{{\color[rgb]{0,0,1} 0.897}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.662}}^{\,***}$ | $0.776^{\,***}$ | $0.604^{\,***}$ | $0.653^{\,***}$ |
Random Forest | $\textbf{{\color[rgb]{0,0,1} 0.673}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.860}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.798}}^{\,***}$ | $0.969^{\,**}$ | $0.913^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.643}}^{\,***}$ | $0.761^{\,***}$ | $0.480^{\,***}$ | $0.639^{\,***}$ |

Notes: see Table 4. For a definition of the subgroups and their respective
weights in the IPCA, see Table A1 in Appendix A.

Some subgroups are equivalent to groups. It is the case of transportation
(inf.sg12 and inf.g5), courses, reading, and stationary (inf.sg18) that is
equivalent to education (inf.g8), and communication (inf.sg19 and inf.g9).
Interestingly, the predictive accuracy obtained from disaggregation into
subgroups is superior to that based on groups, both stacking the horizons and
considering them individually. In particular, the improvements are remarkable
for transportation and communication. The difference between both approaches
is that, while one includes lags from other subgroups and not groups, the
other includes lags from different groups and not subgroups. Note that,
stacking the forecast horizons, while CSR reduces the RMSE of the AR model for
group transportation (inf.g5) by 5%, the RF obtains an average reduction of
14% for subgroup transportation (inf.sg12). For transportation, while the ML
methods using disaggregation into groups do not statistically outperform the
AR model for horizons 1 to 4, 10, and 11 months ahead, some of these methods
employing disaggregation into subgroups generate statistically significant
improvements at the most demanding level ( i.e., 1%) for all these horizons.
For communication, disaggregation into subgroups can improve the already good
performance of methods when employing disaggregation into groups.

####  5.3.4 Further remarks

We find that ML models considering several predictors beat the AR model by a
wide and statistically significant margin for all disaggregates considered.
Comparing the use of group and subgroup disaggregations, the predictive
benefits associated with a higher level of disaggregation appear to align with
the results of Duarte and Rua (2007), for Portugal, Ibarra (2012), for Mexico,
and Bermingham and D’Agostino (2014), for the US and Euro Area. However, upon
revisiting the results of the aggregation of disaggregated forecasts (Tables 1
to 3), we note that the use of disaggregation into subgroups does not generate
more accurate forecasts than the direct approach or aggregation from less
profound disaggregations. A potential explanation for this result is that we
do not consider the aggregation of disaggregated forecasts generated by
different models in this paper. As we have seen, a single model does not
dominate the forecasts of all disaggregates and often does not even exhibit
dominance over time for the same disaggregate (see Figures from D1 to D4 in
Appendix D). Additionally, there is a possibility of inaccurate disaggregated
forecasts occurring at some point in time, which can lead to a deterioration
of the predictive accuracy of the aggregation of disaggregated forecasts.
Importantly, this deterioration cannot be attributed to the use of the most
recent available weights for each item in the consumption basket. When we
conduct the forecasting exercises again using the actual weights, the results
demonstrate no significant changes.

##  6 Conclusion

In this paper, we investigate the use of inflation disaggregations to forecast
the aggregate via aggregation of disaggregated forecasts – what became known
as the bottom-up approach. We innovate by considering multi-horizon forecasts
of several inflation disaggregates in a data-rich environment (i.e.,
considering many predictors), which is only possible by employing machine
learning methods. Analyzing Brazilian inflation and exploring different levels
of disaggregation for inflation, we conduct forecasting exercises from both
direct and bottom-up forecast approaches. We highlight the relevance of
considering the combination of disaggregated analysis and machine learning
methods in the econometrician’s toolbox.

For many forecast horizons, the aggregation of disaggregated forecasts
performs as well as survey-based expectations and models that generate
forecasts directly from the aggregate. Our results reinforce the benefits of
using models in a data-rich environment for inflation forecasting, including
aggregating disaggregated forecasts generated from machine learning
techniques, mainly during volatile periods. During the COVID-19 pandemic,
model-based forecasts, including those based on disaggregated data, tend to
provide more accurate forecasts than survey-based expectations. For example,
the random forest model based on both aggregate and disaggregated inflation
delivers great results for intermediate and longer horizons. The selection of
predictors obtained by the adaLASSO and FarmPredict indicates the importance
of considering a broad and diversified set of variables when forecasting
inflation. Regarding the prediction of individual disaggregates, we find that
ML models considering several predictors beat the AR model by a wide and
statistically significant margin for all disaggregates and the vast majority
of horizons.

This paper can be extended in many ways in future research. Firstly, it is
possible to replicate the procedures analyzed here for other developed and
emerging countries. Secondly, an important possibility is the formulation and
implementation of a methodology that combines different models predicting
different disaggregates. As we have seen, there is no dominant technique.
Thus, to fully exploit the potential of disaggregated forecasting, it is
necessary to combine different forecasts to obtain the aggregate forecast.
Beyond combining different models in the dimension of disaggregates, one can
also combine different models over horizons to improve the forecast of time-
accumulated inflation (e.g., 12-month cumulative inflation). Thirdly,
combining different levels of disaggregation could be valuable since
increasing the level in some branches may be advantageous while for others, it
does not. For example, in the Brazilian price index employed in this paper,
some groups may be worth keeping in the final combination, while others may
benefit from further breakdown into subgroups or deeper disaggregation.
Finally, a fourth possibility not explored in this paper is to use breakeven
inflation as a predictor and benchmark in inflation forecasting.

##  Appendix A Groups and subgroups of the IPCA

Table A1: Description of groups e subgroups of the IPCA

Groups / subgroups | Weight
---|---
Foods and beverages | 23.7
| Food at home | 15.8
| Food away from home | 7.9
Housing | 15.5
| Utilities and maintenance | 10.3
| Domestic fuels and energy | 5.2
Household goods | 4.1
| Furniture and fixtures | 2.0
| Appliances | 1.7
| Household operations | 0.3
Apparel | 5.5
| Clothes | 3.6
| Footwear and accessories | 1.6
| Jewelry | 0.3
| Fabrics | 0.1
Transportation | 19.0
| Transportation | 19.0
Medical and personal care | 12.1
| Pharmaceutical and optical products | 3.6
| Medical services | 5.5
| Personal care | 3.0
Personal expenses | 10.6
| Personal services | 6.6
| Recreation and tobbaco | 4.0
Education | 5.1
| Courses, reading, and stationery | 5.1
Communication | 4.3
| Communication | 4.3

Notes: The column “Weight” shows the average weight of each group and subgroup
in the IPCA from January 2014 to June 2022. The text indicates each group and
subgroup by inf.g# and inf.sg#, respectively, where the # indicates the order
in which each appears in this table.

##  Appendix B Predictive variables

Table B1: Description of predictive variables

# | Abbreviation | Description | Unit | Source | Lag | Transformation
---|---|---|---|---|---|---
A. Prices and Money
1 | inf, inf.bcb#, | IPCA and disaggregations | index | IBGE | 1 | % change
| inf.g#, inf.sg# |  |  |  |  |
2 | expec | Focus-based inflation expectation (available) |  % per month | BCB | 0 | –
3 | inpc | INPC | index | IBGE | 1 | % change
4 | ipca15 | IPCA-15 | index | IBGE | 0 | % change
5 | ipc | IPC-Br | index | FGV | 1 | % change
6 | igpm | IGP-M | index | FGV | 1 | % change
7 | igpdi | IGP-DI | index | FGV | 1 | % change
8 | igp10 | IGP-10 | index | FGV | 1 | % change
9 | ipc_fipe | IPC-Fipe | index | FGV | 1 | % change
10 | ipa | IPA | index | FGV | 1 | % change
11 | ipa_ind | IPA | index | FGV | 1 | % change
12 | ipa_agr | IPA | index | FGV | 1 | % change
13 | incc | INCC | index | FGV | 1 | % change
14 | bm_broad | Broad Monetary Base – end-of-period balance | index | BCB | 2 | % change
15 | bm | Monetary Base – working day balance average | index | BCB | 2 | % change
16 | m1 | Money supply M1 – working day balance average | index | BCB | 2 | % change
17 | m2 | Money supply M2 – end-of-period balance | index | BCB | 2 | % change
18 | m3 | Money supply M3 – end-of-period balance | index | BCB | 2 | % change
19 | m4 | Money supply M4 – end-of-period balance | index | BCB | 2 | % change
B. Commodities Prices
20 | icbr | Brazilian Commodity index (all) | index | BCB | 1 | % change
21 | icbr_agr | Brazilian Commodity index – agriculture | index | BCB | 1 | % change
22 | icbr_metal | Brazilian Commodity index – metal | index | BCB | 1 | % change
23 | icbr_energy | Brazilian Commodity index – energy | index | BCB | 1 | % change
C. Economic Activity
24 | ibcbr | Brazilian IBC-Br Economic Activity index | index | BCB | 3 | % change
25 | month_gdp | GDP monthly – current prices | R$ million | BCB | 1 | % change
26 | tcu | Total capacity utilization – manufacturing industry | % | FGV | 1 | first difference
27 | pimpf | Industry Production – general | index | IBGE | 2 | % change
28 | pmc_total | Retail sales volume – total | index | IBGE | 2 | % change
29 | pmc_fuel | Retail sales volume – fuels and oils | index | IBGE | 2 | % change
30 | pmc_supermarket | Retail sales volume – supermarkets and food products | index | IBGE | 2 | % change
31 | pmc_clothing | Retail sales volume – fabrics, clothing and shoes | index | IBGE | 2 | % change
32 | pmc_house | Retail sales volume – furniture and appliances | index | IBGE | 2 | % change
33 | pmc_drugstore | Retail sales volume – pharmaceutical and cosmetic articles | index | IBGE | 2 | % change
34 | pmc_paper | Retail sales volume – books, newspapers and stationery | index | IBGE | 2 | % change
35 | pmc_office | Retail sales volume – office and eletronical equipments | index | IBGE | 2 | % change
36 | pmc_others | Retail sales volume – others | index | IBGE | 2 | % change
37 | pmc_building | Retail sales volume – building material | index | IBGE | 2 | % change
38 | pmc_auto | Retail sales volume – automotive and parts | index | IBGE | 2 | % change
39 | steel | Steel production | index | BCB | 1 | –
40 | prod_vehicles | Vehicle production – total | units | Anfavea | 1 | % change
41 | prod_agr_mach | Production of agricultural machinery – total | units | Anfavea | 1 | % change
42 | vehicle_sales | Vehicle sales by dealerships – total | units | Fenabrave | 1 | % change
D. Employment
43 | unem | Unemployment (combination of PME and PNADC) | % | IBGE | 2 | first difference
44 | employment | Registered employess by economic activity - Total | units | IBGE | 1 | % change
45 | aggreg_wage | Overall Earnings (broad wage income) | R$ (million) | BCB | 1 | % change
46 | min_wage | Federal Minimum Wage | R$ | MTb | 0 | % change
47 | income | Households gross disposable national income | R$ (million) | BCB | 2 | % change
E. Electricity
48 | elec | Electricity consumption – total | GWh | Eletrobrás | 2 | % change
49 | elec_res | Electricity consumption – residential | GWh | Eletrobrás | 2 | % change
50 | elec_com | Electricity consumption – commercial | GWh | Eletrobrás | 2 | % change
51 | elec_ind | Electricity consumption – industry | GWh | Eletrobrás | 2 | % change
F. Confidence
52 | cons_confidence | Consumer Confidence index | index | Fecomercio | 1 | % change
53 | future_expec | Future expectations index | index | Fecomercio | 1 | % change
54 | conditions | Current economic conditions index | index | Fecomercio | 1 | % change

Table B1: Description of predictive variables (cont.)

# | Abbreviation | Description | Unit | Source | Lag | Transformation
---|---|---|---|---|---|---
G. Finance
55 | ibovespa | Ibovespa index | % per month | B3 | 0 | -
56 | irf_m | Anbima Market Index of the prefixed federal bonds | index | Anbima | 1 | % change
57 | ima_s | Anbima Market Index of the federal bonds tied to the Selic | index | Anbima | 1 | % change
58 | ima_b | Anbima Market Index of the federal bonds tied to the IPCA | index | Anbima | 1 | % change
59 | ima | General Anbima Market index | index | Anbima | 1 | % change
60 | saving_deposits | Saving deposits – end-of-period balance | R$ (mil) | BCB | 2 | % change
61 | selic | Selic Basic Interest rate | % per month | BCB | 0 | –
62 | cdi | Cetip DI Interbank Deposits rate | % per month | Cetip | 0 | –
63 | tjlp | TJLP Long-term Interest rate | % per year | BCB | 1 | –
64 | ntnb | 3-Year Treasury (real) Rate indexed to the IPCA (NTN-B) | % per year | Anbima | 0 | –
65 | embi | Emerging Markets Bond Index Plus – Brazil | b.p. acc. month | JP Morgan | 0 | first difference
66 | vix | CBOE Volatility Index (VIX) | index | CBOE | 0 |
H. Credit
67 | cred_total | Credit outstanding – total | R$ (million) | BCB | 2 | % change
68 | cred_dgp | Credit outstanding as a percentage of GDP | % of GDP | BCB | 2 | first difference
69 | indebt_house1 | Household debt to income – total | % of 12m income | BCB | 2 | first difference
70 | indebt_house2 | Household debt without mortgage loans | % of 12m income | BCB | 2 | first difference
I. Government
71 | net_debt_gdp | Net public debt (% GDP) -Consolidated public sector | % of GDP | BCB | 2 | first difference
72 | net_debt | Net public debt – Total – Consolidated public sector | R$ (million) | BCB | 2 | % change
73 | net_debt_fedgov_bcb | Net public debt – Federal Government and Central Bank | R$ (million) | BCB | 2 | % change
74 | net_debt_states | Net public debt – State governments | R$ (million) | BCB | 2 | % change
75 | net_debt_cities | Net public debt – Municipal governments | R$ (million) | BCB | 2 | % change
76 | primary_result | Primary result – Consolidated public sector | R$ (million) | BCB | 2 | % change
77 | debt_fedgov_old | Gross general government debt – Method used until 2007 | R$ (million) | BCB | 2 | % change
78 | debt_fedgov_new | Gross general government debt – Method used since 2008 | R$ (million) | BCB | 2 | % change
79 | treasury_emit | National Treasuary domestic securities – Total issued | R$ (million) | BCB | 2 | % change
80 | treasury_mkt | National Treasuary domestic securities – Total on market | R$ (million) | BCB | 2 | % change
81 | treasury_term | National Treasury securities debt – medium term | months | BCB | 2 | first difference
82 | treasury_dur | National Treasury securities debt – medium duration | months | BCB | 2 | first difference
J. Exchange and International Transactions
83 | reer | Real Effective Exchange Rate | R$/other | BIS | 1 | % change
84 | usd_brl_end | USD-BRL rate – end-of-period | R$/US$ | BCB | 0 | % change
85 | usd_brl_av | USD-BRL rate – monthly average | R$/US$ | BCB | 1 | % change
86 | eur_brl_end | EUR-BRL rate – end-of-period | R$/€ | Bloomberg | 0 | % change
87 | eur_brl_av | EUR-BRL rate – monthly average | R$/€ | Bloomberg | 1 | % change
88 | current_account | Current account – net | US$ (million) | BCB | 2 | % change
89 | trade_balance | Balance on goods and services – net (Brazilian trade balance) | US$ (million) | BCB | 2 | % change
90 | exports | Exports | US$ (million) | BCB | 2 | % change
91 | imports | Imports | US$ (million) | BCB | 2 | % change

Notes: “Lag” column indicates the delay for each variable to become available
and “Transformations” column indicates transformation implemented to guarantee
the stationarity of the series.

##  Appendix C Forecast performance for disaggregates by horizon

###  C.1 BCB disaggregates before and after the COVID-19 pandemic

Table C1: Out-of-sample RMSE for BCB disaggregate (in terms of RMSE of the AR
model): Jan/2014 to Feb/2020, by disaggregate and horizon

Estimator/Model | $h=0\quad\,$ | $h=1\quad\,$ | $h=2\quad\,$ | $h=3\quad\,$ | $h=4\quad\,$ | $h=5\quad\,$ | $h=6\quad\,$ | $h=7\quad\,$ | $h=8\quad\,$ | $h=9\quad\,$ | $h=10\;\;$ | $h=11\;\;$ | all $h$
---|---|---|---|---|---|---|---|---|---|---|---|---|---
A. Monitored Prices |
AR | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000
Augmented AR | $\textbf{{\color[rgb]{0,0,1} 0.740}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.860}}^{\,***}$ | 0.971 | 0.985 | 1.005 | 1.010 | 1.030 | 1.040 | 1.040 | 1.015 | 1.012 | 1.024 | $0.983^{\,*}$
Ridge | $\textit{{\color[rgb]{0,0,1} 0.744}}^{\,***}$ | 0.952 | 0.990 | 0.979 | 0.987 | 0.975 | 0.994 | 0.991 | 0.998 | 0.977 | $\textbf{{\color[rgb]{0,0,1} 0.942}}^{\,**}$ | $\textbf{{\color[rgb]{0,0,1} 0.929}}^{\,*}$ | $\textbf{{\color[rgb]{0,0,1} 0.958}}^{\,***}$
adaLASSO | $0.795^{\,***}$ | $0.929^{\,*}$ | 0.982 | 0.985 | 0.991 | 0.972 | 0.999 | 0.998 | 1.012 | 1.010 | 0.967 | 0.963 | $\textit{{\color[rgb]{0,0,1} 0.970}}^{\,***}$
Factor | $0.777^{\,***}$ | $0.937^{\,*}$ | 1.018 | 1.011 | 1.013 | 0.995 | 1.019 | 1.028 | 1.036 | 0.994 | 0.976 | 0.961 | $0.983^{\,*}$
FarmPredict | $0.815^{\,***}$ | 0.957 | 1.008 | 1.004 | 1.009 | 1.011 | 0.988 | 0.983 | 1.013 | 0.998 | 0.972 | 0.967 | $0.979^{\,**}$
Target Factor | $0.796^{\,***}$ | 0.921 | 1.004 | 1.011 | 1.069 | 1.076 | 1.056 | 1.202 | 1.151 | 1.091 | 1.052 | 1.012 | 1.043
CSR | $0.950^{\,*}$ | $0.961^{\,*}$ | 0.987 | 0.996 | 1.013 | 1.030 | 1.028 | 1.041 | 1.030 | 1.008 | 0.997 | 1.012 | 1.005
Random Forest | $0.913^{\,*}$ | 0.991 | 1.032 | 1.026 | 1.060 | 1.076 | 1.085 | 1.050 | 1.047 | 1.014 | $\textit{{\color[rgb]{0,0,1} 0.967}}^{\,*}$ | 0.977 | 1.021
B. Non-Tradables |
AR | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 1.000
Augmented AR | $\textit{{\color[rgb]{0,0,1} 0.784}}^{\,***}$ | $0.801^{\,**}$ | $0.830^{\,***}$ | $0.795^{\,***}$ | $0.781^{\,***}$ | $0.735^{\,***}$ | $0.819^{\,***}$ | $0.831^{\,**}$ | $0.914^{\,*}$ | 1.063 | 1.112 | 1.056 | $0.867^{\,***}$
Ridge | $\textbf{{\color[rgb]{0,0,1} 0.763}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.791}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.821}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.792}}^{\,***}$ | $0.775^{\,***}$ | $0.735^{\,***}$ | $0.808^{\,***}$ | $0.820^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.903}}^{\,**}$ | 1.024 | 1.059 | 1.015 | $\textit{{\color[rgb]{0,0,1} 0.850}}^{\,***}$
adaLASSO | $0.850^{\,**}$ | $\textbf{{\color[rgb]{0,0,1} 0.790}}^{\,**}$ | $\textbf{{\color[rgb]{0,0,1} 0.783}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.773}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.746}}^{\,***}$ | $\textbf{{\color[rgb]{0,0,1} 0.709}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.786}}^{\,***}$ | $\textit{{\color[rgb]{0,0,1} 0.778}}^{\,***}$ | $0.922^{\,*}$ | 1.039 | 1.089 | 1.087 | $0.851^{\,***}$