Machine learning model to predict mental health crises from electronic health records

Publication in Nature Medicine by Roger Garriga ’17 and Javier Mas ’17 (Data Science) et al

Article cover in Nature Medicine

The use of machine learning in healthcare is still in its infancy. In this paper, we describe the project we did to predict psychotic episodes together with Birmingham’s psychiatric hospital. We hope to see these sorts of applications of ML in healthcare become the new standard in the future. The technology is ready, so it’s just a matter of getting it done!

Paper abstract

The timely identification of patients who are at risk of a mental health crisis can lead to improved outcomes and to the mitigation of burdens and costs. However, the high prevalence of mental health problems means that the manual review of complex patient records to make proactive care decisions is not feasible in practice. Therefore, we developed a machine learning model that uses electronic health records to continuously monitor patients for risk of a mental health crisis over a period of 28 days. The model achieves an area under the receiver operating characteristic curve of 0.797 and an area under the precision-recall curve of 0.159, predicting crises with a sensitivity of 58% at a specificity of 85%. A follow-up 6-month prospective study evaluated our algorithm’s use in clinical practice and observed predictions to be clinically valuable in terms of either managing caseloads or mitigating the risk of crisis in 64% of cases. To our knowledge, this study is the first to continuously predict the risk of a wide range of mental health crises and to explore the added value of such predictions in clinical practice.

(You can also read about the project in more detail in this article from UPF)

Citation

Garriga, R., Mas, J., Abraha, S. et al. Machine learning model to predict mental health crises from electronic health records. Nat Med (2022). https://doi.org/10.1038/s41591-022-01811-5

Connect with BSE authors

Roger Garriga ’17 is a Research Data Scientist at Koa Health. He is an alum of the BSE Master’s in Data Science.

Javier Mas ’17 is Lead Data Scientist at Kannact. He is an alum of the BSE Master’s in Data Science.

Application of bagging in day-ahead electricity price forecasting and factor augmentation

Publication in Energy Economics by Kadir Özen ’21 (PhD Track) and Dilem Yıldırım

Illustration of an energy plant and city lights with market graph

This paper has been published in the November 2021 issue of the journal Energy Economics.

Abstract

The electricity price forecasting (EPF) is a challenging task not only because of the uncommon characteristics of electricity but also because of the existence of many potential predictors with changing predictive abilities over time. In such an environment, how to account for all available factors and extract as much information as possible is the key to the production of accurate forecasts. To address this long-standing issue in a way that balances complexity and forecasting accuracy while facilitating the traceability of the predictor selection procedure, we propose the method of Bootstrap Aggregation (bagging). To forecast day-ahead electricity prices in a multivariate context for six major power markets, we construct a large-scale pure price model and apply the bagging approach in comparison with the popular Least Absolute Shrinkage and Selection Operator (LASSO) estimation method. Our forecasting study reveals that bagging provides substantial forecast improvements on daily and hourly scales in almost all markets over the popular LASSO estimation method. The differentiation in the forecast performances of the two approaches appears to arise, inter alia, from their structural differences in the explanatory variables selection process. Moreover, to account for the intraday hourly dependencies of day-ahead electricity prices, all our models are augmented with latent factors, and a substantial improvement is observed only in the forecasts from models covering a relatively limited number of predictors.

Highlights

  • We forecast day-ahead electricity prices for major markets with a large-scale model.
  • The method of Bootstrap Aggregation (bagging) is applied to generate forecasts.
  • Bagging appears to be very competitive and promising compared to the popular LASSO.
  • Factor augmentation is proposed to capture intraday hourly dependencies of prices.
  • Augmentation improves forecasts only for models with limited number of predictors.

Connect with BSE authors

portrait

Kadir Özen ’21 is a student in the PhD Program at UPF and BSE. He is an alum of the BSE Master’s in Economics and Finance (PhD Track).

Marta Morazzoni and Andrea Sy win EEA Young Economist Award

Their paper, “Female entrepreneurship, financial frictions and capital misallocation in the US,” has also been published in the Journal of Monetary Economics.

A photo of the two BSE alumni who wrote the award-winning paper, Marta Morazzoni and Andrea Sy, posing together at UPF Ciudatella Campus where they are both PhD candidates.
EEA Young Economist Awardees Marta Morazzoni ’18 and Andrea Sy ’18

BSE alumni Marta Morazzoni and Andrea Sy (both Economics Class of 2018) received the 2021 Young Economist Award from the European Economic Association and Unicredit Foundation for their paper, “Female entrepreneurship, financial frictions and capital misallocation in the US.”

The paper has also just been published in the Journal of Monetary Economics. (It originally appeared as a Barcelona School of Economics Working Paper.)

“New empirical evidence, highly relevant policy implications”

The EEA Young Economics award committee consisted of Philipp Kircher, Giacomo Ponzetto and Antonella Trigari. They noted that “the paper addresses an extremely important topic, offers new empirical evidence from micro-level data cleverly identifying informative moments, and builds a state-of-the-art general equilibrium model to rationalize the evidence and to provide highly relevant policy implications.”

Read the award committee’s report on the EEA website

Paper abstract

We document and quantify the effect of a gender gap in credit access on both entrepreneurship and input misallocation in the US. Female entrepreneurs are found to be more likely to face a rejection on their loan applications and to have a higher average product of capital, a sign of gender-driven capital misallocation that decreases in female-led firms’ access to finance. These results are not driven by differences in observable individual or businesses characteristics. Calibrating a heterogeneous agents model of entrepreneurship to the US economy, we show that the observed gap in credit access explains the bulk of the gender differences in capital allocation across firms. Eliminating such credit imbalance is estimated to potentially increase output by 4%, and to reduce capital misallocation by 12%.

Key findings

  • In the US, female entrepreneurs receive less business funding compared to male entrepreneurs.
  • Female-owned firms operate with lower levels of assets, resulting in gender-driven capital misallocation.
  • Female-led businesses are nonetheless relatively more profitable and have better credit risk scores.
  • Removing the gender gap in business financing is estimated to potentially increase output by 4%.

Connect with BSE authors

portrait

Marta Morazzoni ’18 is a PhD candidate at Universitat Pompeu Fabra and BSE. She is an alum of the BSE Master’s in Economics.

portrait

Andrea Sy ’18 is a PhD candidate at Universitat Pompeu Fabra and BSE. She is an alum of the BSE Master’s in Economics.

The Wisdom of the Crowd: Using ensemble machine learning techniques as an early warning indicator for systemic banking crises

Finance master project by Gabriela Lavagna, Helena Patterson, and Robizon Razmadze ’21

Blurred chart on a computer screen
Image by Pexels from Pixabay

Editor’s note: This post is part of a series showcasing BSE master projects. The project is a required component of all Master’s programs at the Barcelona School of Economics.

Abstract

We develop early warning models for systemic crisis prediction using machine learning techniques on macrofinancial data for 36 countries for quarterly data spanning 1970-2013. Machine learning models outperform logistic regression in out-of-sample predictions under the recursive window forecasting mechanism. In particular, using the ensemble random forest algorithm for both feature selection and prediction substantially outperforms the logit models. We identify the key economic and financial drivers of our models using the random forest framework by extracting each feature’s Gini impurity and corresponding information gain. Throughout the time period, the most important predictors are credit, foreign liabilities, asset prices and foreign currency reserves. 

Conclusions

  • The aim of the study was to construct a machine learning methodology to improve the predictive ability of systemic crises models. We applied these algorithms on macrofinancial data for 36 countries for quarterly data spanning 1970-2013. The results of the paper show that predictions of financial crises are more accurately obtained via machine learning algorithms as opposed to logit regression models in out-of-sample predictions (obtaining an AUC score of 0.77-0.81).
  • During the analysis, our goal was not only to be able to improve the predictive power of the models, but also to be able to select the most relevant and concise predictor variables. We applied the random forest ensemble algorithm to undertake feature selection and concluded that, over the years, the variables credit, foreign liabilities, asset prices and currency reserves were most important in predicting systemic crises.
  • The value-add derived from the models developed by us can be viewed in two main directions: Firstly, the need to use time series data as a means of predicting crises has meant many authors in the past have been unable to avoid the ‘looking to the future’ issue. We managed to alleviate this risk by using a recursive window estimation mechanism. The main benefit of this methodology is that it would allow policymakers to observe the predictors in real-time. Second, by being able to rank variables in order of importance, we were able to reveal the key economic and financial drivers which should be used by policymakers in evaluating any pressing risk of systemic crises. 

Connect with the authors

About the BSE Master’s Program in Finance

Gender Gap and Retirement Decisions: the Maternity Pension Supplement in Spain

Economics master project by Jorge Casanova, Horia Guias, Carlos Javier López, Andrea Salvanti, and Patrick Sewell ’21

Family graphic spray painted on pavement
Photo by Sandy Millar on Unsplash

Editor’s note: This post is part of a series showcasing BSE master projects. The project is a required component of all Master’s programs at the Barcelona School of Economics.

Abstract

Embedded in the growing governmental efforts to reduce the gender income gap, in 2016 a retirement pension supplement for mothers of at least two children was introduced in Spain. Through an Oaxaca-Blinder decomposition analysis, we find that the policy had a smaller-than-expected shrinking effect in the gender gap in retirement pensions. Using a difference-in-differences approach, we identify that the trade-off between the supplement incentivizing early retirement and the penalty this retirement modality entails in Spain is the mechanism driving this result. Finally, we developed a dynamic choice model to simulate women’s behavior under alternative versions of the policy.

Summary

Our main motivation was to analyse whether the maternity supplement proposed by the Spanish government in 2016 fostered gender equality through a reduction of the gender gap in retirement income. We decompose the average monthly retirement income for both men and women into its determinants and estimate how the gender difference in returns on pension of having two or more children changes after the policy is introduced. Our result is that the policy had a smaller-than-expected shrinking effect in the gender gap in retirement pensions, as the gender gap for regular retirement closes but the gap conditional on early retirement (i.e. below 65 years) remains unaffected.

chart

Figure 1: Time Series of Average Monthly Retirement Income: negative trend reverted for women retiring at 65 after the introduction of the policy but not for women retiring at an earlier age.

Using a difference-in-differences approach, we observe that the policy has a positive effect on all retirement hazard rates – i.e. the probability of retiring at a certain age, conditional on not having done so before.

One reason for the lower income effect is due to the trade-off that women face when they consider retiring before reaching the age at which they would start receiving their full retirement pension. On the one hand, early retirement increases the value of leisure, which could be especially beneficial for women with difficult working biographies. On the other hand, early retirement entails a penalty on the pension. For this group of women, early retirement reduces this penalty and hence, changes the trade-off in favour of early retirement, making the substitution of retirement income for more leisure more appealing.

Finally, we develop a dynamic choice model that depicts the trade-off between income and leisure that women face in retirement decisions, which can be used in a next step to simulate different retirement policies and compare their outcomes.

Future research on the maternity benefit ought to shed light on the different effects it produced between women who were and were not in a couple, and how much agents value leisure relative to money.

Connect with the authors

About the BSE Master’s Program in Economics

The role of pensions: Exploring the link between pension funds, monetary policy and economic performance

Macroeconomic Policy and Financial Markets master project by Diljá Matthíasardóttir and Lara Zarges ’21

A grandmother and granddaughter sit on a park bench talking happily about what they see on a mobile phone
Photo by Andrea Piacquadio on Pexels

Editor’s note: This post is part of a series showcasing BSE master projects. The project is a required component of all Master’s programs at the Barcelona School of Economics.

Abstract

Shocks to the European Central bank’s unconventional monetary policy trigger Dutch pension funds to search for yield: A structural VAR analysis shows that the pension funds reallocate their asset holdings from bonds towards equity and alternatives. The latter suggests the existence of a portfolio-rebalancing channel through institutional investors in the euro area. Moreover, we emphasize that the portfolio reallocation induced by monetary policy has increased the overall riskiness of the funds’ investments, which has potentially systemic risk implications. As the pension sector has evolved into a key player in the Dutch financial market, we additionally investigate the domestic real effects of a further increase in its size. In this context, a second SVAR approach shows that an expansive shock to total asset holdings boosts economic growth. As this link also works in the reverse direction, we point out the potential problems of a sudden dissaving of pension funds. Our results are of general interest for the aging societies in Europe as they improve the understanding of pension funds’ potential importance for economic policy in a period of demographic change. This paper hence urges future research to contribute to a better understanding of the link between demographic change, growing pension systems and central bank policies.

Conclusions

We infer that the change in the portfolio composition following a monetary shock to the ECB shadow rate after 2008 is driven by unconventional monetary policy succeeding in lowering the long-term interest rates. The resulting rise in equity and alternatives in the pension fund’s asset holdings can therefore be interpreted as evidence for the existence of a portfolio rebalancing transmission channel of quantitative easing in the euro area.

These findings also imply that due to unconventional monetary policy the riskiness of Dutch pension funds’ portfolios has been increasing gradually. Together with the sheer size of the Dutch pension sector and the funds’ tendency to herd-behavior this might be affecting local financial stability and with it the safety of Dutch pensions.

We further show that the size of the pension sector is a factor influencing economic growth and unemployment in the Netherlands.

Due to structural drivers such as demographic change, interest rates are likely to be lower for longer. We therefore stress the importance of future research on demographic effects such as the evolution of the size of funded pension systems on monetary policy conduction. This is e.g. important considering that the change of the Dutch pension system towards a full DC system in 2027 will most likely alter the consumption and saving patterns of citizens. The importance of bank deposits could shrink, impeding the supply of bank loans to the corporate sector. Firms would then likely turn towards financial securities to finance their operations. This would imply an overall decline in the importance of the credit channel for monetary policy transmission regardless of unconventional times. Therefore, a deeper understanding of the influence of central bank policies on institutional investors and insurers is required. This is especially important since the number of private, complementary pension schemes has been growing in many member states following the European Directive 2003/41/EC.

Connect with the authors

About the BSE Master’s Program in Macroeconomic Policy and Financial Markets

Economic gains from global cooperation in fulfilling climate pledges

Publication in Energy Policy by Sneha Thube ’16 (Economics) et al

Co2, Carbon Dioxide, Carbon, Oxygen, The Atmosphere
Image by Gerd Altmann from Pixabay

My paper “Economic gains from global cooperation in fulfilling climate pledges” (with Ruth Delzeitab and Christian H.C.A. Henning) is now available online.

Paper Abstract

Mitigation of CO2 emissions is a global public good that imposes different regional economic costs. We assess the distributional effects of cooperative versus non-cooperative CO2 markets to fulfil the Nationally Determined Contributions (NDCs), considering different CO2 permit allocation rules in cooperative markets. We employ a global computable general equilibrium model based on the GTAP-9 database and the add-on GTAP-Power database. Our results show the resulting winners and losers under different policy scenarios with different permit allocation rules. We see that in 2030, we can obtain gains as high as $106 billion from global cooperation in CO2 markets. A cooperative CO2 permit market with equal per capita allowances results in considerable monetary transfers from high per capita emission regions to low per capita emission regions. In per capita terms, these transfers are comparable to the Official Development Assistance (ODA) transfers. We also disaggregate the mitigation costs into direct and indirect shares. For the energy-exporting regions, the largest cost component is unambiguously the indirect mitigation costs.

Conclusions

With regard to the initial NDCs, aggregate economic gains from jointly achieving the NDCs are $106bn (i.e. 60% of costs with unilateral action) in 2030. Mobilizing cooperation via Article 6 is important.

When the costs are disaggregated into direct (i.e. domestic mitigation) and indirect (i.e. due to changes in international markets) within the energy-exporters (e.g., Russia, Canada, Middle East and North Africa) the dominant cost share arises from indirect costs.

We also model a scenario using where regional allowances allocated in proportion to the regional population (aka Carbon Egalitarianism) within a global ETS. This approach addresses global equity issues, aligns incentives of all countries & eliminates free-riding problem.

Large financial transfers (~$114bn in 2030) are generated via the carbon markets are leads to welfare improvements in the developing regions. These transfers are comparable to the per capita ODA received by some countries esp. in Sub-Saharan Africa.

The approach based on per capita emission benchmarking has also been suggested by Dr. Raghuram Rajan

If global justice is considered as a global public good, which similar to GHG mitigation, is underprovided, then the principle of carbon egalitarianism could promisingly combine an additional aspect to welfare, giving an important message for policymakers.

Connect with the author

portrait

Sneha Thube ’16 is a researcher at the Kiel Institute for World Economy. She is an alum of the Barcelona GSE Master’s in Economics.

Extreme Weather and Health Outcomes in Women: Evidence from Colombia and Peru

Economics of Public Policy master project by Melina Aliayi, Manohar Gannavarapu, and André López ’21

A pregnant woman in a warm sweater places her hands on her belly, forming a heart shape with her fingers
Image by StockSnap from Pixabay

Editor’s note: This post is part of a series showcasing BSE master projects. The project is a required component of all Master’s programs at the Barcelona School of Economics.

Abstract

This paper investigates the relationship between health outcomes during delivery and extreme temperatures in Colombia and Peru. 

We used geo-coded household survey data from the Demographic and Health Survey Program (DHS), allowing us to construct an index accounting for the incidence of pregnancy complications in women during labor. Matching these health outcomes indicators with monthly-temperature data at a grid-cell level, we find that experiencing extreme temperatures during pregnancy, particularly cold temperatures, increases the probability of suffering pregnancy complications in the case of Colombia. Contrary to majority of the literature on health outcomes and temperature, we find no effect of experiencing extreme high temperatures. Interestingly, we find no significant effects in Peru.

Conclusions

  • We identify that experiencing at least one month of extreme cold temperatures during pregnancy increases the incidence of pregnancy complications by 2.5%.  
  • Shifting the analysis to the trimester level, we find that experiencing extreme cold temperatures during the first and third trimester of pregnancy increases the probability of pregnancy complications. 
  • Furthermore, we find an additional effect by wealth. Being poor increases the probability of experiencing pregnancy complications due to extreme cold temperatures by an additional 5%.

Connect with the authors

About the BSE Master’s Program in Economics of Public Policy

Save The Euro Policy: European Debt Crisis and Covid-19 Pandemic

Economics master project by Kadir Özen and Hirotaka Ito ’21

Euro bills and face masks

Editor’s note: This post is part of a series showcasing BSE master projects. The project is a required component of all Master’s programs at the Barcelona School of Economics.

Abstract

The 2008-2009 Global Financial Crisis led to European debt crisis leaving the periphery of euro zone with very high borrowing costs compared to core countries. When Covid-19 Pandemic Crisis hit the economies, monetary policy tools of European Central Bank prevented a similar debt crisis. We identify the underlying factor of the ECB monetary policy that is active during the 2011-2012 debt crisis and Covid-19 Pandemic periods operated through sovereign spreads preventing the contagion of fragmentation risk of euro area. We call this new factor, save-the-euro with which we shed light on the monetary policies of this unusual periods.

Conclusions

  • Identified the new dimension of the ECB Policy, save-the-euro policy, that captures stabilization policy of ECB that works through euro zone sovereign yields
  • This policy addresses euro area fragmentation risk 
  • An expansionary save-the-euro policy leads to a highly statistically significant appreciation of Euro against US dollar: Sharp contrast with the standard textbook treatment
  • Document the reversal of flight-to-safety flows in the euro area

Connect with the authors

About the BSE Master’s Program in Economics

Green Agreement in the Electricity Market

An ex-post evaluation of the 2013 Dutch Coal Power Plants Closure Agreement by Ilaria Noviello and Shaun Tey ’21

Smoke stacks
Photo by Andreas Felske on Unsplash

The full title of this project is “Green Agreement in the Electricity Market: An ex-post evaluation of the 2013 Dutch Coal Power Plants Closure Agreement.”

Editor’s note: This post is part of a series showcasing BSE master projects. The project is a required component of all Master’s programs at the Barcelona School of Economics.

Abstract

There has been much theoretical discussion on whether Green Agreements can be a cost efficient means of improving the sustainability of products, but no empirical studies have been done on what the cost and benefits of past Green Agreements have been. 

In order to provide a substantive contribution to this discussion, we have undertaken an ex-post analysis of an agreement in the Netherlands to close five aging coal power plants in 2016 and 2017. First, we evaluated the ACM’s assumption that the plant closures would result in an increase of the Dutch wholesale electricity price in the Netherlands by undertaking a before-and-after analysis. Second, we examined how the ACM quantification of the benefits deriving from emissions reductions would have changed if it used its same methodology a year after the plants closed (in mid-2018). Third, we considered how the quantification of the benefits would have changed if the ACM used an alternative evaluation technique based on estimating consumers’ willingness to pay for Green Electricity.

Our findings indicate that the ACM was likely incorrect to oppose the agreement to close the coal power plants.

Conclusions

  • The before-and-after analysis indicates that the agreement to close the coal power plants did not result in any increase in the wholesale price of electricity in the Netherlands. This implies that this Green Agreement had no cost, while still producing a benefit of reduced emissions.
  • Our examination of the ACM’s method for quantifying the benefits derived from reduced emissions finds it to be volatile. In particular, due to subsequent changes to the methods used by the Dutch Government for valuing reduced emissions, the benefit of the Closure Agreement would be regarded as far higher if evaluated today. 
  • We find that it is unviable to use an alternative evaluation technique based on estimating consumers’ willingness to pay for Green Electricity.

Our conclusion suggests that those working on ex-ante assessments of Green Agreements should recognise that the volatility of their government’s approach to environmental policy can alter the accuracy of their assessments. As a result of this, regulators should coordinate better across government departments, in order to understand which methodologies are currently subject to scrutiny and could possibly change in the future.

Connect with the authors

About the BSE Master’s Program in Competition and Market Regulation