A Deep Reinforcement Learning Framework for the Financial Portfolio Management Problem

Zhengyao Jiang, Dixing Xu, Jinjun LiangarXiv 2017

Abstract

Financial portfolio management is the process of constant redistribution of a fund into different financial products. This paper presents a financial-model-free Reinforcement Learning framework to provide a deep machine learning solution to the portfolio management problem. The framework consists of the Ensemble of Identical Independent Evaluators (EIIE) topology, a Portfolio-Vector Memory (PVM), an Online Stochastic Batch Learning (OSBL) scheme, and a fully exploiting and explicit reward function. This framework is realized in three instants in this work with a Convolutional Neural Network (CNN), a basic Recurrent Neural Network (RNN), and a Long Short-Term Memory (LSTM). They are, along with a number of recently reviewed or published portfolio-selection strategies, examined in three back-test experiments with a trading period of 30 minutes in a cryptocurrency market. Cryptocurrencies are electronic and decentralized alternatives to government-issued money, with Bitcoin as the best-known example of a cryptocurrency. All three instances of the framework monopolize the top three positions in all experiments, outdistancing other compared trading algorithms. Although with a high commission rate of 0.25% in the backtests, the framework is able to achieve at least 4-fold returns in 50 days.

Introduction

Portfolio management involves the continuous redistribution of capital across various financial assets to maximize returns while managing risk. Traditionally, this has been approached through rigid financial models or supervised learning techniques aimed at price prediction. However, these methods often struggle with the gap between prediction and actionable trading decisions, as well as the scalability issues inherent in managing a large number of assets simultaneously.

This paper introduces a model-free Deep Reinforcement Learning (RL) framework designed to bridge these gaps. Unlike traditional RL applications that focus on discrete "buy/sell/hold" actions for single assets, this framework addresses the complexities of real-world portfolio management, which requires continuous weight adjustments across a fluctuating asset pool.

Methodology

The proposed framework introduces three core innovations to handle the temporal and structural complexities of financial markets.

Ensemble of Identical Independent Evaluators (EIIE)

To ensure scalability, the authors utilize the EIIE topology. Instead of a single monolithic network, the system employs "mini-machines" (implemented as CNNs, RNNs, or LSTMs) that evaluate each asset independently while sharing the same parameters. This weight-sharing approach allows the model to learn general market behaviors rather than asset-specific histories, effectively mitigating survival bias and enabling linear scalability to any number of assets.

Portfolio-Vector Memory (PVM) and Transaction Costs

A critical challenge in RL for trading is accounting for transaction costs, which are a function of the change in portfolio weights. To address this, the framework incorporates a Portfolio-Vector Memory (PVM). The PVM stores the portfolio weights from the previous period, allowing the network to factor its current state into the next decision.

Temporal sequence of the portfolio management process showing the transition of weights and prices over time.

As shown in the figure above, the transition from the end-of-period weights ($w'_t$) to the rebalanced weights ($w_t$) involves a "buy/sell" action that incurs costs. By feeding $w_{t-1}$ back into the network via the PVM, the agent learns to avoid excessive rebalancing that would diminish profits through commission fees.

Online Stochastic Batch Learning (OSBL)

The OSBL scheme facilitates "on-the-fly" learning. It samples mini-batches from historical data using a geometric distribution, prioritizing recent data to ensure the model remains relevant to current market conditions. The reward function is defined as the explicit average logarithmic cumulated return, allowing the agent to directly optimize for wealth accumulation.

Experimental Setup

The framework was evaluated using data from the Poloniex cryptocurrency exchange. The dataset included the 11 most-traded non-cash assets, with Bitcoin serving as the "cash" base. Three back-test experiments were conducted with 30-minute trading periods between late 2016 and mid-2017. Input features for each asset included closing, high, and low prices over the preceding 50 periods (25 hours).

Results

The framework was tested using three different neural architectures: CNN, basic RNN (bRNN), and LSTM. In all experiments, these RL-based agents outperformed traditional algorithmic trading strategies such as Anticor, OLMAR, and PAMR.

Despite a significant commission rate of 0.25%, the CNN-based agent achieved a 29-fold return in the first 50-day back-test and an 8-fold return in the second. Furthermore, the agents demonstrated high stability and superior Sharpe Ratios, indicating consistent growth with minimal drawdowns compared to benchmarks.

Discussion and Conclusion

The success of the EIIE framework highlights the advantages of RL over traditional regression-based price prediction. By optimizing directly for the end goal—portfolio wealth—and incorporating transaction costs into the learning loop via the PVM, the model achieves robust performance in volatile markets.

However, the study operates under the assumptions of "Zero Slippage" and "Zero Market Impact," which may not hold for large-scale institutional trading. Future research could explore dynamic asset selection using "critic" networks and test the framework's applicability in lower-volatility markets like Forex or traditional stock exchanges.

Summary updated

BibTeX
@misc{jiang2017deep,
  author = {Zhengyao Jiang and Dixing Xu and Jinjun Liang},
  title = {{A Deep Reinforcement Learning Framework for the Financial Portfolio Management Problem}},
  year = {2017},
  eprint = {1706.10059},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1706.10059},
}
Figure