I am currently trying to adapt a model to a long short portfolio strategy. The model is stated here: A Deep Reinforcement Learning Framework for the Financial Portfolio Management Problem by Jiang, Xu, and Liang https://arxiv.org/abs/1706.10059

In Eq. (1-10), the portfolio process is formulated. The portfolio weight vector w can have only positive values in this long-only setting. Instead, I now adapted the network to output a weight vector of positive and negative values whose absolute values sum up to one, where positive (negative) values represent going long (short). When looking at the equations, one quickly sees that the portfolio equations do not work correctly anymore if the weight vector can have negative values, mostly because of the definition of yt, which is the price return expressed as a factor from time t-1 to t. For instance, yt = vt/v[t-1] where v are the prices of the individual assets. As a first fix, I tried to take 1/yt instead of yt whenever the corresponding weight is negative. Then, in the following equations, I can simply use the absolute of the vector w, and the equations should come out right then. However, in this way, i believe, the network does not really learn to set the weights correctly. Instead, now, i am trying to reformulate the equations correctly for a weight vector that can take negative values, as well. My first try was to replace yt*wt by 1 + (yt-1) * wt in all the equations. This seems to work (although I am not sure whether the values of the short positions are then correctly computed), but for Eq.(7), it fails. So there must be a different, more elegant approach to adapt the model to long short without having to change much in the loss functions, portfolio value computation, etc. Any ideas? I appreciate it!

Best, JC

  • 1
    $\begingroup$ A portfolio with nonnegative weights that sum up to one is a very different thing that one where weights can be negative also. What is the purpose of your requirement that they sum up to one? This does obviously not limit the portfolio weights in any way. $\endgroup$
    – Kurt G.
    Sep 3, 2021 at 14:28
  • $\begingroup$ Hey, thanks for the response. The condition is not that the weights sum up to one, but that their absolute values sum to one. In my view this should result in a weight vector that outputs positive and negative values between 0 and 1. Each of the individual values in w would then represent the fraction of total capital that is invested in a long or short position where pos and neg values represent long or short positions respectively. The equations then should be adapted to be correct for w which can contain negative values. $\endgroup$
    – user101893
    Sep 5, 2021 at 15:50
  • $\begingroup$ You are obviously right that when only the non-absolute values should sum to one, this would not really result in a meaningful expression for the portfolio vector (unless you allow for unlimited leverage maybe). What can also be done to circumvent rewriting the equations would be to always first output a weight vector with real values, then replace the asset factor returns yt by their inverse values 1/yt for the assets where the corresponding w-values are negative and then compute the equations with the absolute values in w (which sum to one). $\endgroup$
    – user101893
    Sep 5, 2021 at 15:51
  • $\begingroup$ But this seems to me rather like a messy workaround as opposed to the more elegant way of simply adapting the portfolio equations. $\endgroup$
    – user101893
    Sep 5, 2021 at 15:52


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.