1 Introduction

The literature on the development of news-based economic policy uncertainty (EPU) indices is gradually emerging, and currently, the existing indices are limited to developed and emerging economies (see Baker et al. (2016), Davis (2016), and Ahir et al. (2022)Footnote 1,Footnote 2. In other words, it is hard to find a version of any of these EPU indices being replicated for any African country despite increasing representation in the global economic integration and strong growth experience over the years (OECD 2018). In bridging this gap, we construct the index for Nigeria as the continent’s largest and most developed economy. As the largest producer of oil in the continent, some specific uncertainty-triggered events, such as oil price shocks, usually culminate into panic buying and selling and often lead to a rise in the level of uncertainty in the country. Similarly, discussion around fuel subsidy removal and its implication for fiscal sustainability also has a way of infusing uncertainty into the economic atmosphere of the country. This peculiarity to the Nigerian economy is the sudden rise in the prices of goods and services that usually follow each time this debate ensues. Other sources of uncertainty such as unexpected and sudden central bank intervention, policy inconsistencies after elections or when power shifts from one party to another, fall in global oil prices, oil price shocks, and uncertain government response, unethical public policy and practices (see Ozili 2022), among other sources that are peculiar to Nigeria, have strengthened our interest in this economy.

In addition to addressing Nigeria’s underrepresentation in the construct of country-level economic policy uncertainty index (see Ozili 2022), this study is an attempt to circumvent wrong policy recommendations that could arise from analyzing Nigerian fundamentals using the global index as well as conditional volatility of some macro variables (see Aye and Kotur 2022; Kumeka et al. 2023), which might not accurately reflect the domestic dynamics in the country. To our knowledge, ours is the first attempt to construct a country-specific uncertainty index for an African country, especially Nigeria, and use the same to predict the behaviour of market fundamentals such as exchange rate and stock return volatility, as well as inflation and inflation variance in the country.

This study presents a daily index for economic policy uncertainty within the context of Nigeria. Our index covers most of the prominent newspapers in Nigeria, such as the Punch, This Day, The Guardian, Business Day, Daily Trust, Tribune, PM news, and Leadership newspapers.Footnote 3 We utilize several keywords similar to those of Baker et al. (2016), Davis (2016), and Ahir et al. (2022) to make the outcome comparable to the existing EPUs (see Al-Thaqeb and Algharabali 2019 for a detailed review). For each of these newspapers, we retrieve daily news articles containing terms such as uncertainty, uncertain, uncertainties, economic, economy, senate, deficit, the central bank of Nigeria, legislation regulation, house of representatives, house of reps, national assembly, and CBN, published between 2010 and 2023. It is important to highlight the approach followed to produce the index is not trivial. Unlike Baker et al. (2016), Davis (2016) and Ahir et al. (2022), it is more tedious to extract the news articles for Nigeria as virtually all of them do not have APIs that provide seamless access to their news content. This may be why Nigeria has not been included in the computation of global uncertainties. Thus, we had to adopt alternative tools to extract the keywords. These alternative tools include Web Scraping, Sitemaps Access, and RSS Feeds.Footnote 4 One important selling point of our index is that it is of daily frequency, and therefore, information about public sentiments on any policy decision in the country will come in handy for relevant authorities to review and process further actions. In addition, with our daily data scope covering the period of 1/1/2010–3/9/2023Footnote 5, we offer Nigeria’s first comprehensive daily dataset on the EPU index. It is, however, important to highlight that our study relates to those of Baker et al. (2016), Davis (2016), and Ahir et al. (2022), except that we focus on the continent that is hardly represented in the construction of country-specific indices including EPU index. Thus, we contribute to the growing literature using articles published in the prominent newspapers of Nigeria to construct the uncertainty index. Similar efforts include the geopolitical risk constructed by Caldara and Iacoviello (2019), climate policy uncertainty by Faccini et al. (2021), global fear index due to COVID-19 by Salisu and Akanni (2020), uncertainty due to COVID-19 pandemic by Narayan et al. (2021), among others. We hope to extend the literature on Africa to the mentioned indices, which currently lie outside the focus of this study.

We test the applicability of our EPU index by conducting some empirical exercises with a number of financial series, such as stock price and exchange rate, to assess how these series connect with the index as established in the literature (see, for example, Xu 2020). Our choice of variables for the empirical application is motivated by their high exposure to systematic and unsystematic risks (see De Santis 2018). We show results that lend credence to the predictive contents of the constructed EPU index for Nigeria. More importantly, we demonstrate that including the index in the predictive models for financial series, such as exchange rate and stock prices, improves their forecasts.

Following this introduction, the rest of the paper is structured thus. Section 2 presents the steps involved in constructing the EPU index. While the penultimate section demonstrates and presents the results from the empirical application using the EPU index, the final section, Sect. 4, anchors the study’s conclusion.

2 Methodological procedure for the EPU index

2.1 Data collection

Developing a text-based index usually begins with identifying relevant keywords related to the subject matter: economic policy uncertainty. Note that several EPU indices are already published (see https://www.policyuncertainty.com/), albeit focusing on developed and emerging economies without any representation from Africa. One common feature of these indices is that they adopt similar keywords whose choice is pioneered by Baker et al. (2016) to facilitate cross-country comparison of datasets. In light of this, we adopt similar keywords such as uncertainty, uncertain, uncertainties, economic, economy, senate, deficit, the central bank of Nigeria, legislation, regulation, house of representatives, house of reps, national assembly, and CBN. Meanwhile, some keywords that reflect the peculiarities of Nigeria, such as the Central Bank of Nigeria, House of Representatives, National Assembly, and CBN, are included to produce a more realistic index for Nigeria.

The second step involves downloading all available news articles and extracting relevant news articles containing these keywords from eight notable newspapers in Nigeria. As previously noted, the newspapers are Punch, ThisDay, The Guardian, Business Day, Daily Trust, Nigerian Tribune, PM news, and Leadership. Table 1 shows the number of newspapers downloaded and those containing at least a keyword. At the end of the procedure, we obtain daily word counts for each keyword over the period of 1/1/2010–11/30/2022.Footnote 6

Table 1 Some useful highlights of the EPU index for Nigeria

2.2 Index construction

To construct the index, we sum the daily word counts for all the keywords, defined in this paper as EPU (i.e., Economic Policy Uncertainty), and thereafter, we run a heteroskedasticity-consistent ordinary least squares (OLS) regression of EPU on day-of-the-week dummy variables to accommodate the possible distinct variations in public sentiments in the five days of the week.Footnote 7 To avoid a dummy trap, we exclude the Friday dummy while the resulting constant and residuals from the OLS model are added to adjust the data for day-of-the-week effects:

$$EP{U_t} = \alpha + \sum\limits_{i = 1}^4 {{\beta _i}{D_{i,t}} + {\varepsilon _t},\,\,\,} i = 1,2,3,4;\,\,\,\,\,\,t = 1,2, \ldots ,T$$
(1)

where EPU is the daily sum of word count for each of the keywords; \({D_{i,t}}\) is for the week-day dummy variables for four days (for a 5-day week) since one dummy has to be excluded to avoid dummy trap; \(\alpha\)is the regression constant while \({\varepsilon _t}\) is the disturbance term. In the appendix (Table A1), we present the regression estimates for the dummy variables of the day-of-the-week effects, which are significant. The (day-of-the-week) adjusted EPU (\(EPU_{t}^{{adj}}\)) is obtained as \(EPU_{t}^{{adj}}=\hat {\alpha }+{\hat {\varepsilon }_t}\). In the final step, we compute the index as:

$$EPU_{t}^{{adj}}{\text{ index}}=\left( {\frac{{EPU_{t}^{{adj}} - \hbox{min} \left( {EPU_{t}^{{adj}}} \right)}}{{\hbox{max} \left( {EPU_{t}^{{adj}}} \right) - \hbox{min} \left( {EPU_{t}^{{adj}}} \right)}}} \right)*100$$
(2)

3 Some empirical analyses

3.1 Some preliminary analyses

We have prepared a dedicated website to host and disseminate the datasets for the \(EPU_{t}^{{adj}}\)index (see https://epuindexng.com/). We cover the period of January 01, 2010 – November 30, 2022, and datasets are available for daily, weekly, and monthly frequencies. In this section, we offer to study the behaviour of the \(EPU_{t}^{{adj}}\)index in two ways. One, we provide some descriptive statistics and graphical representations of the index, and two, we complement one with some data analyses that attempt to connect the index with the predictability of relevant financial variables, such as exchange rates and stock prices, that are assumed to respond to uncertainties. We present the descriptive statistics in Table 2 for different daily, weekly, and monthly frequencies. Expectedly, we show that the dispersion of the index declines with lower frequency judging by both standard deviation and coefficient of variation. This observation is also evident in Figs. 1 and 2, and 3, where daily frequency shows greater dispersion than weekly and monthly, while the latter has the least dispersion. Even the formal tests for serial correlation and conditional heteroscedasticity in Table 3 show larger values of the test statistics for a higher (daily) frequency than a relatively lower (monthly) frequency. In addition, a closer look at the figures suggests greater uncertainties since 2015, coinciding with the period of oil price shock, economic recession, and the COVID-19 pandemic up to the period of the Naira redesign policy and its fallouts.

We also probe further to tease out any possible connection between Nigeria’s index and exchange rate by providing graphical evidence, as depicted in Fig. 4. We can find a somewhat positive connection between exchange rate appreciation and the index, a piece of evidence that is empirically investigated in the next section. In other words, higher economic uncertainties may drive higher depreciation of the Naira. Similarly, rising economic uncertainties discourage increased investments in the stock market as the two variables seem to be negatively related (see Fig. 5).

Fig. 1
figure 1

Trends in the daily\(EPU_{t}^{{adj}}\)index, January 01, 2010 – November 30, 2022

Fig. 2
figure 2

Trends in the weekly\(EPU_{t}^{{adj}}\)index, January 01, 2010 – November 30, 2022

Fig. 3
figure 3

Trends in the monthly\(EPU_{t}^{{adj}}\)index, January 2010 – November 30, 2022

Fig. 4
figure 4

The connection between Nigeria’s index and exchange rate, March 2012 – November 30, 2022

Fig. 5
figure 5

The connection between the\(EPU_{t}^{{adj}}\)index and Stock prices in Nigeria, March 2012 – November 30, 2022

Table 2 Descriptive statistics of the\(EPU_{t}^{{adj}}\)index
Table 3 Formal tests of the\(EPU_{t}^{{adj}}\)index

3.2 In-sample and out-of-sample predictability of the \(EPU_{t}^{{adj}}{\text{ index}}\)

3.2.1 The predictive model

We construct a predictive model distinctly for the realized volatilities of the exchange rate and stock returns where the \(EPU_{t}^{{adj}}{\text{ index}}\)serves as a predictor.Footnote 8 There is increasing evidence in the literature supporting the inclusion of news-based EPU indices in the predictability of financial series (see for a review, Al-Thaqeb and Algharabali 2019). Our predictive model theoretically aligns with Benanke’s (1983) observation that high levels of uncertainty incentivize businesses to postpone hiring and investment when personnel are expensive to hire and dismiss, or investment projects are costly to cancel. Similar to this, Myers and Majluf (1984) show how the pecking order theory can influence the stock market in the event of economic policy uncertainty. Moreover, the Arbitrage Pricing Theory effectively captures the relationship between uncertainty and market fundamentals such as stock returns and exchange rates. Thus, our predictive model follows these theories, particularly the Arbitrage Pricing Theory, as it provides the most accurate predictions of market fundamentals, including stock returns (see Kisman and Restiyanita 2015).

For empirical modelling, our predictive model follows the approach of Westerlund and Narayan (2012, 2015), which simultaneously accounts for some salient data features typical of high-frequency time series, such as persistence and conditional heteroscedasticity, as exhibited by our variables (see Table 3). Recent studies using this methodology have demonstrated its usefulness in improving predictability outcomes (see, for example, Narayan and Bannigidadmath 2015; Narayan and Gupta 2015; Phan et al. 2015; Bannigidadmath and Narayan 2016; Devpura et al. 2018; Salisu et al. 2019a&b). In addition, we account for possible shifts in the realized volatilities of the exchange rate and stock returns based on the day-of-the-week effect. If it exists, accounting for any inherent level shift in the series tends to enhance the predictability of outcomes (see Salisu et al. 2019a, b; among others). Given this background, the predictive model is written as:

$$R{V_t}=\alpha +\rho R{V_{t - 1}}+\beta EPUI_{{t - 1}}^{{adj}}+\gamma \left( {EPUI_{t}^{{adj}} - \psi EPUI_{{t - 1}}^{{adj}}} \right)+\sum\limits_{{i=1}}^{4} {{\delta _i}DU{M_{i,t}}} +{\varepsilon _t}$$
(3)

where \(R{V_t}\) is a 22-day realized volatility of Nigeria’s exchange rate/stock returns computed at period t; \(EPUI_{t}^{{adj}}\) is the log-transformed news-based economic policy uncertainty index for Nigeria at the time t; \(DU{M_{i,t}}\) is the \({i^{th}}\)day-of-the-week dummy; \(\alpha\) is the intercept; \(\beta\) is the predictability coefficient; \(\gamma \left( {EPUI_{t}^{{adj}} - \psi EPUI_{{t - 1}}^{{adj}}} \right)\) is included to correct for any bias resulting from persistence effect \(EPU_{t}^{{adj}}\); \({\delta _i}\) is the coefficient for the day-of-the-week dummy; \({\varepsilon _t}\) is a zero mean idiosyncratic error term. Since we are using daily data, it will not be out of place to suspect the conditional heteroscedasticity effect (in fact, our preliminary test in Table 3 confirms this suspicion). Thus, to resolve this effect, we pre-weight Eq. (2) with the standard deviation of its residuals and, thereafter, re-estimate the resulting equation with the Ordinary Least Squares to obtain the Feasible Quasi-Generalized Least Squares estimates (see Westerlund and Narayan 2012, 2015).

In the final set-up, we evaluate the forecast performance of Eq. (3) relative to the benchmark (driftless random walk) model. We use the Clark and West (2007) [Clark-West] test to evaluate the forecast performance of the competing models since both are nested. A statistically significant positive value implies the outperformance of \(EPUI_{t}^{{adj}}\)-based model the benchmark model and vice versa for a statistically significant negative value. We utilize 75:25 data split for both the in-sample predictability and out-of-sample forecast evaluation. In the out-of-sample period, we consider 40-, 80- and 120- (daily) periods ahead of forecast horizons under a rolling window framework that allows for some time variation. The corresponding weeks and months are used for the predictability involving weekly and monthly frequencies, respectively.

3.2.2 Results and discussion

We begin our analyses with Eq. (3) which is the model without any additional (control) variable, and thereafter, we estimate an extended version that includes oil price volatility as a control variable. The connection between oil price and exchange rate (see, for example, Huang et al. 2020; Salisu et al. 2020) on the one hand and oil price and stock returns (see, for exampleNarayan and Gupta 2015; Salisu et al. 2019c, d) on the other hand is well established in the literature. Note that both variants of the predictability analyses involving daily data include the day-of-the-week effects while they are expectedly excluded for weekly and monthly frequencies. In the case of the former, all the differential intercept coefficients are statistically significant (see Table A2 in the appendix), indicating the existence of these effects in the behaviour of both exchange rate and stock returns. In Table 4, we present only the predictability coefficient of the EPU index under the two model scenarios (with and without an additional (control) variable) and for three different frequencies, daily, weekly and monthly. The full results are presented in the appendix (see Tables A2, A3, and A4 for the daily, weekly, and monthly frequencies, respectively).

We utilize the full data sample to establish the relationship between the EPU index and the selected financial series. For forecast analyses, 75% of the data sample is used for the in-sample estimation, while the out-of-sample forecast evaluation is determined from the balance. As expected, we show that the index significantly influences the behaviour of the exchange rate and the stock market in Nigeria (see Table 4). More specifically, the index positively relates to exchange rate return volatility for daily and weekly frequencies (in line with our observation in Fig. 4), while it is negative for the monthly frequency. In other words, for the positive association, we can conclude that higher uncertainties create negative signals in the domestic economy, which may discourage capital inflow and thus raise the level of currency depreciation (Krol 2014). The negative relation between the index and exchange rate volatility for the monthly frequency is not far-fetched, given that the official exchange rate is used in this study. In the case of Nigeria, which is characterized by managed floating exchange rate mechanism, the monetary authority intervenes at intervals to moderate any noticeable deviation between the official and “market-based” exchange rates. Therefore, any significant volatility in the exchange rate in the early days of a month can be moderated by the month-end with the intervention of the monetary authority. We, however, observe consistent results for the stock market since this market is largely market-driven and does not enjoy the kind of interventions extended to the foreign exchange market in Nigeria. Specifically, we establish a negative connection between the index and stock return volatility (as depicted in Fig. 5), indicating that higher uncertainties may discourage future investment in the stock market, thereby reducing trading activities and, by extension, market volatility. Our results for stock return volatility and the associated impact of uncertainty (EPU index) on investment support the findings by Baker et al. (2016) who equally establish a negative nexus between EPU and global investment, output and employment. In the same vein, empirical evidence by Iqbal et al. (2020) highlights negative influence of EPU on US-based firms’ performance. This is plausible, given the role of EPU on currency depreciation as shown in our results. Currency depreciation especially for import-dependent country such as Nigeria portend high cost, which could reduce firm’s profit margin. Given the foregoing, Dai et al. (2017) demonstrate that EPU index can affect currency exchange rates and equally has some predictive ability for return on investments in future exchange rates.

We also conduct some simple forecast analyses using the Clark and West (2007) measure of forecast evaluation since the competing (restricted and unrestricted) models are nested. We present the results in Tables 5 and 6, and 7 for daily, weekly, and monthly data frequencies, respectively. Our index offers more accurate forecasts for the examined financial series than the benchmark model. We observe greater forecast outcomes for the stock market than the foreign exchange market as the forecast outcome for the former consistently improves across the three data frequencies and over the forecast horizons, unlike the latter, where the benchmark model outperforms the index-based model at a lower frequency. As noted previously, the incessant interventions of the relevant authority in the foreign exchange market may limit the predictability of the index at a lower frequency during which such interventions are undertaken. In other words, investors in the stock market tend to monitor the state of macroeconomic conditions when making investment decisions. This outcome also aligns with the Arbitrage Pricing Theory, which assumes that individual stocks respond to macroeconomic risks. In sum, the outcome lends credence to the appropriateness and adequacy of the index in measuring uncertainties in Nigeria.

As a form of additional analysis and in response to the request by one of the reviewers, we also extend the evaluation of the predictive prowess of our proposed EPU index for Nigeria to inflation. We are considering two types of inflation in this case: (i) actual inflation, which is computed from the year-on-year percentage changes in monthly consumer prices, and (ii) inflation risk, which is calculated using the realized volatility of inflation based on a three-month rolling window. Most economic outlook reports are done on a quarterly basis, so the inflation risk that manifests within this quarter has a greater tendency to influence investor and business expectations about the future behaviour of inflation. Due to the unavailability of inflation data at higher frequencies, we can only conduct analyses on a monthly basis, unlike the stock prices and exchange rate scenarios. We present the results in Table 8 both for the in-sample and out-of-sample predictability. We find that a higher incidence of economic policy uncertainties tends to raise the level of inflation and inflation risk. This behaviour extends to the out-of-sample performance, where the consideration of the index improves the out-of-sample forecast results of inflation. Overall, the index offers useful predictive content for both financial and macro variables, and therefore, when constructing predictive models for these variables in the country of focus, we encourage the inclusion of the index to improve the forecast results and minimise any inherent bias in the estimation process.

Table 4 In-sample predictability results for the\(EPU_{t}^{{adj}}\)index
Table 5 Daily out-of-sample predictability results for the\(EPU_{t}^{{adj}}\)index [Using Clark and West (2007) test]
Table 6 Weekly out-of-sample predictability results for the\(EPU_{t}^{{adj}}\)index [Using Clark and West (2007) test]
Table 7 Monthly out-of-sample predictability results for the\(EPU_{t}^{{adj}}\)index [Using Clark and West (2007) test]
Table 8 In-sample and out-of-sample predictability results for the \(EPU_{t}^{{adj}}\)index in the inflation model

4 Conclusion

Our effort in this study is to fill an obvious gap in the literature in the computation of economic uncertainty indices. It is generally observed that all the African countries are hardly captured in the existing indices, thus making it difficult to conduct related studies on Africa. With the increasing uncertainties associated with the aftermath of the COVID-19 pandemic and the Russia-Ukraine war and how such are projected to impact the African continent, the proposed EPU index will come in handy when making investment and policy decisions at least for one of the leading countries in Africa. This is the motivation for the study. Thus, as a preliminary step towards providing a platform that tracks the extent of uncertainties in Africa, we focus on its largest economy, Nigeria, while we hope to extend this exercise to other emerging economies on the continent in the foreseeable future.

Essentially, the economic policy uncertainty index involves prominent newspapers in Nigeria. We scrape their articles to identify relevant keywords, which are then used to construct the index. Consequently, we offer several analyses to test the predictability of the index, particularly for exchange rate and stock return volatility. We find that the index contains useful predictive contents that can be exploited to improve the out-of-sample forecast of exchange rate and stock returns, albeit with greater out-of-sample predictive power for the latter when a lower frequency is used. Overall, the index more prominently positively connects with the exchange rate, while it does so negatively with stock returns. In other words, higher uncertainties can cause the exchange rate to depreciate further, and similarly, it can discourage future investment in the stock market. The outcome aligns with the theoretical and empirical literature evidence regarding how uncertainties connect with economic and financial variables. Given that the proposed index is available at a high frequency, information about public sentiments on any policy decision in the country will come in handy for relevant authorities to review and process for further actions. Similarly, the results generated from testing the nexus between our index and some financial and macro fundamentals would serve as a useful guide to investors on significance of factoring policy uncertainty in their investment decisions, and to always exercise caution during heightened uncertainty in the country. Finally, future studies can extend the literature on Africa by constructing country-specific policy uncertainty index for some other African countries. Also, indices focusing on other measures of uncertainties such as geopolitical risk index, among others can be constructed for Africa given the rising geopolitical tension in the Western and Central Africa sub-regions.