Theory

It has been hypothesized that certain common psychological barriers exist in financial markets that cause traders to reverse their trading practices when those barriers are approached.

An attempt is made to test the viability of algorithmic trading of CME Globex Euro/Dollar (6E) futures contracts based on the theory of support and resistance, using pivot point calculations.

The CME Globex 6E futures contract normally trades during a 23-hour "trading day" that ends at 4pm, having begun at 5pm the previous day. (On Mondays, trading begins at 3pm Sunday).

Calculation

Step 1:
Every single trade made on GLOBEX during a 10-month period is collected, and the data extracted for a few typical 23-hour trading-days, chosen more or less at random.
Plot

Step 2:
Daily summary data is calculated for the 10-month period, including trading date (date that 23-hour trading day ended), time of first trade, time of last trade, and the previous trading-day's open, high, low, close, volume, largest-single-trade, and number of trades.


Volume
This is calculated with a short C program that outputs a summary data file.

Summary data file [17k]

Step 3:
A simulation is run of several trading days with another C program that calculates the theoretical "pivot points" of a given trading-day, and chronologically travels through the entire day's trading, applying the theory of support and resistance lines to select the correct moments to enter into futures-contract positions. Results are determined.

This simulation determines the correct times during a trading day to enter a futures contract position using a Stop-Stop-Limit Order, an order to Buy (or Sell) futures contracts that will automatically exit the position when a certain number of profit points have been gained, or when trading goes against us, and an unacceptable maximum number of points have been lost.

The correct moment to enter a position is based on when trading on the market has led to a price that is approaching a pivot point, but is at a specific safe distance (offset) from it. The other prerequisites to entering a position include that trading has travelled a minimum distance from a recent low (or high) price, enough of a movement suffiently significant to indicate a trend.

When the program begins, technical pivot points are determined based on standard formulas that calculate them using the prior trading day's high, low, and closing prices.

The calculations used are taken from Wikipedia:

http://en.wikipedia.org/wiki/Pivot_point_calculations

The program then proceeds to analyze every trade of a specified trading-day chronologically, simulating when positions are entered and when they are exited. For simplicity, the program assumes that desired orders are always filled at the current trading price, and that positions are always successfully closed at one of the specified stop-gain or stop-loss order prices.

Each "roundturn" (the two trades used to enter and exit a position) is reported, along with a summary total of number of points gained/lossed from the day's trading.

The logic is:

      BUY if
      price = RESISTANCE-6 AND (price - 20min LOW) >= 10 AND last_line_crossed=RESISTANCE
      
        OR
      
      SELL if
      price = SUPPORT+6 AND (price + 20min HIGH) >= 10 AND last_line_crossed=SUPPORT

Online Simulator/Calculator

A live web-based simulation also exists for fine-tuned experimentation.

Results

1/16 16 January 2008 Results
      23 roundturns:
       0   longs  (0.00%)
      23   shorts (100.00%)
      16   were profitable   (69.57%)
       7   were unprofitable (30.43%)
  Sum of differences: -0.0001
  
3/18 18 March 2008 Results
     107 roundturns:
       0   longs  (0.00%)
     107   shorts (100.00%)
      73   were profitable   (68.22%)
      34   were unprofitable (31.78%)
  Sum of differences: -0.0019
  
7/22 22 July 2008 Results
      23 roundturns:
       0   longs  (0.00%)
      23   shorts (100.00%)
      17   were profitable   (73.91%)
       6   were unprofitable (26.09%)
  Sum of differences: 0.0009
  
7/23 23 July 2008 Results
      16 roundturns:
       0   longs  (0.00%)
      16   shorts (100.00%)
      12   were profitable   (75.00%)
       4   were unprofitable (25.00%)
  Sum of differences: 0.0008
  
9/19 19 September 2008 Results
      94 roundturns:
      92   longs  (97.87%)
       2   shorts (2.13%)
      66   were profitable   (70.21%)
      28   were unprofitable (29.79%)
  Sum of differences: 0.0002
  
10/6 10 October 2008 Results
      62 roundturns:
      36   longs  (58.06%)
      26   shorts (41.94%)
      52   were profitable   (83.87%)
      10   were unprofitable (16.13%)
  Sum of differences: 0.0086
  

Conclusion

The summary conclusion, after testing with numerous alternative sets of pivot points, time windows, and entry/exit rules, tested over numerous different trading-days, is that the end gain/loss result will always statistically approximate zero, as it would if the pivot points had been selected at random. This suggests that, at a minimum, the traditional pivot point calculations do not reflect the behavior of the market.