Background
My friend Jack and I have an early love for cryptocurrencies in common. We both had invested individually but started a fund together in the autumn of 2015 in anticipation of the Bitcoin reward halving in July 2016. Jack has an amazing relationship network and soon we had lined up a large fund from a diverse group of investors. Most people bought in at a price of around $250 and with the price rising to well over $500 we took profit and had a group of very happy investors.
We then started discussing on how we could ensure continued ROI of the fund. I had been busy with robotics and machine learning and suggested that we build a neural network that could give us some support with our buy/sell decisions.
The Team
We managed to assemble a great team for this. We have:
- Ewan from London with great relations in the financial service industry
- Mahesh an IT expert from Bangalore
- Ashish a mathematician from Delhi
- Tim from Switzerland a deep learning guru
- Jack a business executive from London
- Myself with good relations in the Private Equity sector
Data
When you want to work with Neural Networks the first thing you need is data. Lots of data. That’s why data is also called the new oil. Neural Networks are only effective if you have massive amounts of data. If you are looking for data I can recommend https://www.quandl.com. They have assembled a great collection of databases to get you started.
Ewan was of great help with his knowledge of which data was already widely used in the models of the financial services sector.
The Neural Network
We started of with a simple LSTM network with 4 input nodes and 100 hidden nodes and started of with the usual input variables such as:
- Difficulty
- Volume
- Price of Gold
- Exchange rate of USD/CNY
We trained the network and below you can see regression between those 4 variables:
Even with those variables alone the Neural Network had already a decent fit. We cycled through more than 500 input variables and finally settled on 20. We will keep these 20 a secret for now.
Anyway now it was time to crank up the network and here is where Tim with his good relations with Nvidia came in. Nvidia with its powerful GPU’s and focus on machine learning could become quite an important player in this area and we hope that they will continue their focus on making deep learning accessible for developers. Here are the results of 100 days of trading with the Neural Network predicting the price of Bitcoin.
Not bad I would say but with some annoying outliers. All in all it has assisted our trading but still requires a lot of knowledge of the crypto market to make the right buy/sell decisions. However I see a lot of potential in Neural Networks assisting in trading decisions. We all know that trading volume, difficulty, the price of gold, the USD/CNY rate, etc. etc.have some impact on the bitcoin price but it is just impossible for a human being to weigh all these variables at the same time.
Next Steps
We are experimenting with a number of strategies to improve our Neural Network further. Some of them are:
- Selection of different input variables
- The use of Nonlineair Autoregressive Networks to predict trading patterns
- Better use of moving averages in our model to predict further ahead
Let me know what you think of the use of Neural Networks in Bitcoin and drop me a line if you want to help in this exciting area.