Can Bitcoin transaction activity predict stock prices?
It's an interesting question, especially considering the infamous volatility of Bitcoin exchange rates. But perhaps market transactions are more telling, and activity in the real world equates to activity online.
I took data from http://blockchain.info/charts, specifically the historical data on the number of transactions since the inception of Bitcoin. The .csv file required some modification as well. You can see the file I used here: http://pastebin.com/raw.php?i=6qbLE4gi
My algorithm is pretty basic. On any given day, I calculate the average of the past three days of transaction activity. If Bitcoin market activity is greater than this three-day average, I buy; otherwise, I sell. I also fluctuate the amount ordered a bit based on the magnitude of the change; perhaps a bigger increase in Bitcoin market activity is associated with a bigger increase in stock price. I start from September 2009, when Bitcoin market activity truly begins to stabilize (relatively, since speaking of stability and Bitcoin is an oxymoron).
This is my first algorithm, so if you have any suggestions or improvements, I'd love to hear, and feel free to mess around with it. One thing I'd like to know is whether my algorithm avoids the common time travel issue.