This is what cryptocurrencies look like in three dimensions — 3D analysis part 1.
21 Jan. 2018 — Today I’ve spent most of my time changing the charting library (from ChartJS to PlotlyJS). I must admit that Plotly is much richer, but also a bit harder to customize and lacks a few elements.
The screenshot below is the new chart. It looks almost identical to the previous ones. However, it’s not very convenient to set interval ticks on X-axis for the date/time (e.g. hourly, 1minute, 5 minutes, …). In ChartJS this was automatically generated, here I have to mess around with code to get it right. I do like the fact that PlotlyJS comes with a toolbox which allows me to zoom in, select, drag, scroll, … This was not possible in ChartJS.
Once I was done with the above, I immediately tackled a new challenge. For quite some time I wanted to cluster data visually and this is one of the reasons I changed to PlotlyJS — it has 3D charts.
The idea is to use clustering to categorize coins by their “stage”, as suggested by @Ensil. I haven’t gotten to this part yet, so that’s still work in progress.
My first attempt was to visualize 3 variables: time, hype and price. But this didn’t appear to be very meaningful (a 2D chart was better for this). My second attempt was: hype, price, trading volume (past 24hrs) — yet again not much to conclude for this plot.
But the following did have something to say:
I have plotted (for the past 24hours, with 2-min intervals): time, BTC/USD price and trade volume (24hrs). Here are a few things we can conclude:
- The cluster where most trades were done ==> the price was lowest (so at midnight UTC Jan. 22): buy low.
- There is a specific cluster between volumes 115k and 120k, where the price was highest: sell high.
- All volumes in between the highest price and lowest price are people who were too late to the selling/buying party — or don’t know what the heck is going on.
Here’s a slightly different angle of the above 3D plot:
22 Jan. 2018 — I’ve been playing a bit more with the 3D plot today (this time with 8 hours more data than yesterday). First I have visualized the Volume on a regular 2D chart:
The yellow area is the price (at hourly intervals). The dark red line is the traded volume (for the past 24 hours) at each hourly interval. However, we are more interested in the purple line, which is the difference (delta) of the currently traded volume and the traded volume of the previous interval. This allows us to see if at some time ‘t’ there were more or less trades compared to the previous interval. Notice that it can be negative if there were less trades, and positive if there were more ( zero if the volumes were equal ).
From this chart we can conclude that most trades were done when the price dropped. Each volume-peak corresponds to a price-valley. But as soon as the price starts going up, the trading volume drops (people don’t buy/sell).
Here’s another way to look at this situation. In the past ±30 hours the price has dropped from about $12.5k to just about $10.5k :
If we rotate the plot a bit, we see that the volume went up as people started to sell/buy. They sold either out of fear or bought out of opportunity.
Here’s a rotating gif animation I’ve made:
Someone asked me why use 3D plots, do they contribute anything at all? I had that thought at first as well. But as I kept looking more and more into the 3D shapes, it started making more and more sense.
We must look at data from different perspectives in order to discover something new.
Thanks to the 3D volume-price-time plot I could see the pattern of supply & demand much better than on a 2D plot. So I’m looking for patterns in 3D shapes that could help me visualize things in 2D better and/or maybe even help me make better prediction algorithms.
For instance, I would personally use the 3D to determine when to buy or sell. When I look at the plot for the past ±36 hours, I see when most trades were done. And so if we could have such a plot across many days/weeks — we could identify whether we are on the far left or the far right of the plot (relative to the volume). So for instance, right now is a good time to buy because a lot of people are selling. We see a small cluster evolving “between 12:00 and 18:00 GMT” where people are buying/selling like crazy.
But that’s more of a philosophical thing. Right now 2D plots are a key priority.
Take care all :)
- Ilya Nevolin