Pages

Thursday, 7 February 2013

11.1 The Weekend Dip

Note:
This post was edited on 11th Februray to remove incorrect references to the MTGOX US$ / BTC VWAP.

0. Introduction
This reddit post reminded me of the Weekend Dip trading strategy, most clearly stated in this bitcointalk.org post by Stephen Gornick. Simply put, the idea is that if the US$ / BTC price is trending down, then a dip is likely to occur on the weekend, for reasons stated in the post.

From the post:
The Weekend Dip strategy that had seen gains that were better than just maintaining a buy and hold position for much of 2011 is detailed below..... From a long position, evaluate late Wednesday evening (U.S.) / Thursday (morning Europe, afternoon east).  If the 7-day high is below the previous 7-day high, then sell some.  If that 7-day high is above the previous (i.e., week-over-week is trending up), then this is not a good weekend to try to play the weekend dip strategy.
I wanted to see if this strategy worked as suggested, or if the strategy perhaps no longer worked, or only worked for a time in 2011, or was a simple case of confirmation bias. More simply, would using the Weekend Dip strategy gain more than buying on any weekend, and more importantly would the gain be better than a buy and hold?

I considered using periodograms  and spectral analysis or ARIMA modelling, but I wanted to keep the analysis simple and easy to understand. Instead I decided to simply collect all the weekend data since the start of MTGOX trading and record weekends when the trend over the last week and a half was negative.

There are immediately two issues: how do you decide whether a weekend experienced a dip in price, and how do you decide to analyse the trend? I attempted to keep this simple so any reader can recreate the results using spreadsheet software.

Datasets:
Daily VWAP MTGOX US$ / BTC
Weekly VWAP MTGOX US$ / BTC



1. Detrend the data
The first step when searching for periodic data is to detrend the data - remove any up or down trends, so one datapoint can be compared with another. One simple method is to fit a smoothing spline to the datapoints, and subtract each data point from the smoothing spline.

Another even simpler method I've used here is to find the percentage change from Friday's mean price to the minimum of Saturday and Sunday's mean price. I've used the VWAP ( volume weighted average price ) rather than a simple mean since that generally follows market trends better, but if you can't calculate that the median price will be close.

The percentage change can be most easily calculated by taking the difference between the logs of subsequent datapoints, and then applying the exponential function. This results in postives datapoints that will be centred on ( or hopefully slightly below ) 1.0 or 100%.

2. Find the recent two week trend
As mentioned above, the strategy should only be used if the market is trending down. Again, a smoothing spline could be used to determine the trend, and the Augmented Dickey Fuller test would do an even better job.

However smoothing splines and the Augmented Dickey Fuller test are not spreadsheet friendly, so instead I used the method described in the post: Take the weekly high between Thursday mornings ( UTC ), and only record the percentage difference between Friday's VWAP and min( Saturday VWAP, Sunday VWAP ) if the weekly high is less than the previous week's high.

3. Results
The first chart is the complete history of the daily VWAP for the MTGOX US$ / BTC price, for reference.

The second chart shows the percentage changes for every weekend. There is no obvious regular dip on weekends without the "market trending down" strategy.

The third chart shows the weekend percentage changes  when the correct Weekend Dip strategy is being used.


4. Conclusion
It's rather difficult from the above to determine whether or not the Weekend Dip strategy is better than simply selling every Friday and buying every weekend or for a buy and hold  and for which epochs the Weekend Dip strategy has been more effective.

To do that, we'll need to compare the cumulative return per trade, and I'll post those results in the next few days.




Donations help give me the time to analyse bitcoin mining related issues and post the results. If you enjoy or find them helpful, please consider a small bitcoin donation:
12QxPHEuxDrs7mCyGSx1iVSozTwtquDB3r

Thanks to the following for use of their data:
bitcoincharts.com: 1kqHKEYYC8CQPxyV53nCju4Lk2ufpQqA2








No comments:

Post a Comment

Comments are switched off until the current spam storm ends.