Closed turmeric-blend closed 3 years ago
I more than appreciate the questions:)
The general philosophy behind deepdow
is that the loss function is king. It represents the actual performance of your strategy. Ideally, one would want to throw a lot of data at the network (that has a reasonably flexible architecture) and not even care what it does in the background.
With that being said, the network architecture and especially the final allocation layer, can be used as a prior. In other words, it is a way how to encode some domain knowledge that could potentially help the network do a better job than having let's say a plain softmax at the end.
To comment on what you said, matching the loss and the cvxpy
objective is definitely a possibility. Check out this example where it is demonstrated that deepdow
can actually arrive at the same results standard convex optimization https://deepdow.readthedocs.io/en/latest/auto_examples/end_to_end/iid.html#sphx-glr-auto-examples-end-to-end-iid-py
However, in general the final allocation cvxpy
layer can be preceded by multiple other layers that output a covariance matrix and expected return vector that do not correspond to their empirical counterparts at all. In this case, one can see the cvxpy
allocation layer as a nice way how to guarantee that the weights sum up to 1 + other constraints. However, one cannot really give the convex optimization any real word interpretation. That is why the loss function is the only thing that really matters.
Thank for your insights. I might try to code up some Risk Budgeting/Parity
and Sharpe Ratio
allocation layers if its possible.
The corresponding PR #98
The risk budgeting was done.
Hi sorry for so many questions this is a learning process for me.
What is the relationship between mean-variance based
Allocator
layer and loss function?From my limited understanding, there are other mean-variance approaches besides
Markowitz
, for exampleSharpe Ratio
andRisk Parity
. So if were to be usingSharpe Ratio
as my loss function, wouldn't it be more suitable to also use an allocator based onSharpe Ratio
as well, thus performing convex optimization on a convex version ofSharpe Ratio
. Similar withRisk Parity
and other mean-variance approaches that are able to be converted to a convex form. Does this makes sense? Or would the performance be similar to usingSharpe Ratio
as loss function withMarkowitz
allocator for example.