Rajandran R Founder of Marketcalls and Co-Founder Algomojo. Full-Time Derivative Trader. Expert in Designing Trading Systems (Amibroker, Ninjatrader, Metatrader, Python, Pinescript). Trading the markets since 2006. Mentoring Traders on Trading System Designing, Market Profile, Orderflow and Trade Automation.

Buy at Today’s Close and Sell at Next day Open – Do Simple Trading Strategies Really Work? [Part2]

2 min read

Do simple Trading strategies really work in Indian Markets? This curiosity in me raised again, after looking into a simple backtest buy at today’s close and sell at next day open which produced phenomenal returns of whopping 568% since 1993 in SPDR S&P 500 ETF (US Market). How about doing similar BTST strategy in Nifty Futures?

But in order to do trading (Buy & sell transaction in the regulated exchanges), trader also involved in paying to the Exchange(Turnover Fees), SEBI(Regulatory Fee) , Govt(STT, Stamp Duty,GST,incomes tax if any), Broker (Brokerage) and to the market (Slippages). If you are a frequent trader possibly you could know that it is really tough to Buy exactly at market close and sell exactly at market open. Due to quick movement in market price, one has to buy or sell at a higher price than the anticipated price at market open or market close. Call it as market slippages or market volatility.

One way to perfect the simple BTST (Buy today sell tommorow) to a near real-time trading rule is converting the trading strategy to Buy Nifty Futures (Go Long) exactly at 3:15 p.m i.e very close to market square off time and Sell (Exit Long) Exactly at Next Day 9.30a.m to avoid market volatility at market open we sell 15min from the market open.

Backtesting Settings

Symbol Nifty Futures
Timeframe 1 min
Trade Execution MKT order
Dataset Length Jan 2011 – Jun 2018
Trading Commissions + Slippages 0.00%
Initial Capital 1,00,000
Position Sizing 1 lot or 75 shares per trade (Fixed shares)
Holding Period Overnight BTST Strategy

What one could get is a stunning & superior result just by playing this simple rule. Returns are a whopping 595% returns since 2011 on a 1 lakh capital and betting one lot of Nifty Futures every time.

Equity Curve of 595% returns (Zero Transactional Cost Involved) on 1 Lakh Capital

Backtesting Results when No/Zero trading cost involved

So where is the catch? The real catch is there in transactional cost. Since the trading rule makes a trade every day, transactional cost plays a major rule in deciding the fate of the trading system in long term. So I now tried with 0.02% of the transactional cost (Exchange(Turnover Fees), SEBI(Regulatory Fee) , Govt(STT, Stamp Duty, GST, incometax if any), Broker (Brokerage) and to the market (Slippages)).

Backtest with 0.02% transactional cost

Surpringly, the system lost 67% of initial capital (1 Lakh) within 185 trades and there is no enough margin to take the next trade. So in order to place right position size, I increased the initial capital to 2 Lakhs this time. The system survived the worst drawdown period and able to make an absolute return of 94.65% over a period of Jan 2011 – July 2018. In compounded terms, Annual returns (CAGR) comes around 9.3%

Equity Curve with 2 Lakhs Initial Capital and 0.02% trading cost

Equity Curve with 2 Lakhs Initial Capital and 0.02% trading cost

Amibroker AFL – Buy Nifty Futures (Go Long) exactly at 3:15p.m and Sell (Exit Long) Exactly at Next Day 9.30a.m.
https://gist.github.com/d391fdc282d560a73126b827b07b4ddc

Conclusion

Undoubtedly, most of the market performance comes by holding positions overnight. However one cannot capitalize the entire performance returns majorly due to higher number of trades involved and transactional cost. The key learning is just dont carried away with some viral backtest report circulated in social media groups. Try to get into deeper insights to understand the nuances and the risky nature involved.

Rajandran R Founder of Marketcalls and Co-Founder Algomojo. Full-Time Derivative Trader. Expert in Designing Trading Systems (Amibroker, Ninjatrader, Metatrader, Python, Pinescript). Trading the markets since 2006. Mentoring Traders on Trading System Designing, Market Profile, Orderflow and Trade Automation.

What is QuantZilla?

Quantzilla is 75+ hours of code mentoring program designed for noncoders who want to learn the coding program right from designing indicators, scanners, trading...
Rajandran R
58 sec read

Things to Consider While Building a Bracket Order Execution…

Building a Bracket Order Strategy is the most demanded request we got from most of the algomojo traders. This article explains the list of...
Rajandran R
12 min read

PlaceOrder – Multi Broker Exectuion Code Snippets for Amibroker

This tutorial explains how to build a button trading right from scratch and with a click of a button how you can send orders...
Rajandran R
7 min read

4 Replies to “Buy at Today’s Close and Sell at Next day…”

  1. That is a great insight and would save many a shirts. Can someone please tell me where can I find historical 30 min ieod data for futures in CSV format. I need for last 10-12 years.

  2. Hi Rajandran,

    Can you share the results for this:
    if we short nifty when market opens and square it off at market closing.

  3. i plot psar in amibroker and tradetiger but psar value is different in amibroker and tradetiger.what is the problem i canot understand plz help me

Leave a Reply

Get Notifications, Alerts on Market Updates, Trading Tools, Automation & More