Portfolio optimization of cryptocurrencies

in #crypto7 years ago (edited)

Hello guys,

first things first. I am new to steemit and I want to introduce myself with this post.
I am a semiconductor physicist but I'm also very interested in financial markets.
Last Year I wrote an simulation about a portfolio optimization of DAX-stock and I was very surprised about the good output.

First I shortly explain the private project “Portfoliooptimization of the DAX-Data“ and then I want to discuss (with you) if it makes sense to apply this simulation on the cryptocurrency market.

The following program was developed in Shell Script and Python and features a
portfolio optimization program on historical stock data with simulations on the future.

Bildschirmfoto 2017-06-13 um 17.57.16.png

A Shell Script was used to download the stock data from the finance.yahoo server. Once
modified it is executed in a time of a few milliseconds. It can easily be extended to
download every stock data of any arbitrary company or cryptocurrency. However, in this
project I just focussed on the German stock index (DAX).

Running the Python program the CSV-data downloaded from the Shell Script are implemented and afterwards the Simulated Annealing algorithm calculates an optimized portfolio to the chosen conditions of e.g. the investment capital or the selected risk. To customize the energy or cost function I become acquainted with the portfolio theory of
Markowitz. Hence, the following cost function was implemented:

Bildschirmfoto 2017-06-13 um 17.59.32.png

Here, the quantity of a single stock is given by wi ∈ N. The first term of Eq. 1 represents
the chief constituent of the program, the profit one obtains by simply subtracting the
stock value at the start time (µt0) from the end value (µte). Since one is interested in steady increase of the deposits the second term represents the linear regression. To minimize the risk of a slump in prices of a portfolio consisting of stocks of only one special branch e.g. the automotive industry (BMW, VW, etc.) the third term was introduced.
The matrix A describes the correlation of the stocks among each other, which guarantees
diversification and thus risk reduction. The constant parameters C1,C2,C3, which describe
the significance of each term, has to be adjusted properly.

Bildschirmfoto 2017-06-13 um 18.02.25.png

To verify if the program operates properly I calculated the portfolio for the past and
afterwards simulated the obtained configuration with the pseudo future. This pseudo
future are also stock values from the past but they haven’t been considered in the simulation.
Thus, one can check the result of the simulation, see Fig. 1. The following table
shows the simulation parameters.

Bildschirmfoto 2017-06-13 um 18.03.28.png

Note that with sufficient computing power the swap value could be much higher to get
an even better profit. Figure 4 shows a graphical result of the simulated stock portfolio.

Bildschirmfoto 2017-06-13 um 18.04.21.png

Bildschirmfoto 2017-06-13 um 18.05.20.png

My question now is:

Do you think such a simulation makes sense applied to cryptocurrencies?

I'm glad to hear about the comments :)

If there are any questions in understand or if you want the source code feel free to comment !!!

Sort:  

Welcome to the platform, I wish everything work out for you. It’s not easy here but not difficult neither but just ask an extra effort, engagement is the key good luck I’m @goodaytraders Start by following people and they will do the same.

Welcome to steemit community. You will love it. Following links may help you to get started.
New Users Guide: https://steemit.com/welcome
Dos and don’ts on Steemit:https://steemit.com/steemit/@najoh/dos-and-don-ts-on-steemit
ChainBB Steem Forum: https://steemit.com/chainbb/@jesta/chainbbcom-a-blockchain-forum-platform-for-steem

Welcome to Steemit @the.maett :)

Welcome Bot Banner

I am a bot that greets new users of the community.

Make sure to participate in this weeks giveaway to get known in the community!

Here are some helpful resources to get you started:

If you have any questions about steem, just ping reggaemuffin, the creator of this bot with your question :)


If you find this bot helpful, give it an upvote! It will continue to upvote introduction posts. Your upvote will give it more power in that. If you think you have something all new users should know, please tell.


See what this is all about and support the bot: SteemGreet the second - submit your links!

Coin Marketplace

STEEM 0.16
TRX 0.13
JST 0.027
BTC 58306.22
ETH 2596.07
USDT 1.00
SBD 2.39