June 4


First Of The Month Market Edge

By Jeff Swanson

June 4, 2012

automated trading, currency futures, day trading, EasyLanguage, ES, futures trading, market studies, S&P Emini, stock index futures, system trading, trading software, Video

In this article I’m going to try something a little different. All the articles up until today were all written as a traditional article that required you to read through them. That of course, will continue. However, I often find it easier and more helpful to create short videos to explain ideas and concepts. So, in this article there is an associated video to go along with it. The article is much shorter as most of the content is within the video. I think you will find this helpful and I plan on creating more videos in the future to accompany articles. I have a feeling a few people will be unable to view the video so, there will be some bugs to work out. Please let me know if you are unable to view the video. Please leave any feedback, questions or problems in the comments below this article.

With the new month of June we are seeing the Bears awaken as the market takes a hit. This big plunge got me wondering how does the first trading day of each month historically perform? What I want to look for are potential market edges in the S&P futures market. These potential edges could likely be applied to the ETF SPY and to other indexes.

I created a simple EasyLanguage strategy to explore the first-of-the-month phenomena. Using a 5-minute bar chart I created a strategy  called “First Of The Month”. It simply  goes long at the market open (835 Central actually since the order is placed at market open and executed on the next bar) and closes the trade at the market close (1500 Central). The system has no stops and no slippage or commissions were deducted. The test was conducted from the year 2000 until June 1, 2012. Below is an equity graph of the results.

It did get off to a very choppy start and up until the last 20 trades or so we are in a strong drawdown. However, we can see that buying on the first of the month and selling at the close appears to have an edge. Remember this is not a trading system, but a study to see if we can find a potential edge to exploit. So far this looks interesting, but let’s take this further.

I then used the EasyLanguage strategy to test each month independently. I was curious to see which month(s) might hold the best edge. By optimizing the “test month” input parameter over the values 1-12 we get the following graph:

Reading from left to right we have each bar representing a calendar month. January on the far left and December on the right. We can see  the months of February, March, April and May are strong. Also the two months of July and October are positive performing months. December and June show a lot of weakness. Shorting on the first of those months may prove profitable, but that’s for another day.

In the video associated with this post I continue by testing a regime filter and a stop loss value. Watch the video to see all the details. The code for this market study is below.

Jeff Swanson

About the author

Jeff has built and traded automated trading systems for the futures markets since 2008. He is the creator of the online courses System Development Master Class and Alpha Compass. Jeff is also the founder of EasyLanguage Mastery - a website and mission to empower the EasyLanguage trader with the proper knowledge and tools to become a profitable trader.

  • Hey Jeff, Great presentation. Would be interesting to look at holding for the entire month and the impact of the election year cycle. Thanks, R.S.

  • Hi Jeff,

    Nice work. I agree with your stop loss analysis, I did this study in EL and tried different profit targets. closing at end of day is best, better than any profit target. However, I have great reservations against avoiding certain months for trading this strategy – unless there is some economic rationale behind leaving them. June and December are the most losing months and both represent end of half years. Also, over the last 7 months of the year (from June-Dec) which are generally negative, July and October are the most profitable months and they represent beginning of third and fourth quarters. Do you think end of half years being losing months and beginning of quarters (Jul and Oct) being positive months – have any significance? Do you think there is any economic rationale behind it? I am very curious to hear your opinion. Like 401ks etc. going into market on 1st of month – which lead to this beginning of month edge. Because otherwise this might be just curve-fitting since we have so little amount of data (like 12 Julys, and 12 Octs etc.). Thank you very much for this fine work.

    • Glad you liked the study, George. I agree about the idea of avoiding certain months unless there is some other fundamental rationale behind it. I have some vague ideas on what might be happening, but I really can’t say. There are books/article dedicated to cycles, but I have not followed them very closely. However, the first thing that pops into my head is mutual funds and/or hedge fund activity around the half-year and end-of-year selling holdings to lock in profits. They all want to show growth in their reports and selling at the end of important fiscal calendar dates may have an impact. Thus, the end of quarters generally may have more selling pressure. The dumping of stocks in december may be partly due to tax strategies as well. Both people and companies using losses to offset gains and then repurchasing the following month. Just a thought.

      • Hi Jeff,

        Thanks for your observation. I thought about this for whole day yesterday and looked at many resources. CXO has research on out-performance of beginning of quarter effects. I think that pretty well explains positive returns for July and October. However, Dec and Jun being so negative – I am still not sure why. I was ‘possibly’ wrong when I said possible reason could be related to Dec and June being end of half years. The dates on which we are measuring are 1st Dec and 1st June, so end of half year selling from hedgies is not really relevant, because on 1st Dec and 1st Jun, we still have 1 full month to go before half year ends.

        But in any case, I am going to implement this strategy for my live trading. I plan to use MA35 filter and trade 10 months a year. I will not trade on 1st June and 1st Dec (just because they are most highly negative). I will use full margin from Jan to May and for July and Oct and half margin for the Aug, Sep and Nov. Once again, thanks for this article. Looking forward to more great articles from you in future. Cheers.

  • {"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}

    Learn To Code & Build Strategies
    Using EasyLanguage.