First I gathered 3 months of data from various APIs und concatted it into one single dataframe. The result looked like this:
I dropped the row with the “Close” statements and Google keywords and prepared the data for correlation:
Log return is used, because the change of percentage can be summed up over time and this dataframe is made out of time series data.
Then I created a correlation matrix out of this:
Afterwards I visualized the correlation matrix with seaborn:
What do we learn from this? To be honest I thought the Bitcoin price would have a stronger correlation to the Google searches of the keyword “bitcoin”. Surprisingly the correlation between the Bitcoin price and the keyword “blockchain” is stronger than this. Bitcoin correlates the most with Nasdaq, S&P500 and the DowJones, which was not a huge surprise. It seems like there is a strong correlation between Bitcoin and US indices.
Next step would be to test rolling correlation, or if there is a lagged correlation, as the BTC price often needs some time to adjust to the market. When I get a chance, I’ll update this article with it.