Cointegrated Pairs

10 months, 3 weeks agoComments closed

pairs-trading tips

At techpaisa, you can analyse a pair of stocks to see the pairs trading strategy results here. We analysed over 6,500 pairs to find out profitable pairs. Here is a list of pairs which have been chosen among thousands of pairs. These pairs contain stocks which are traded in futures.

Frequently asked questions on pairs trading click here.

Good Trading!

Techpaisa Team.

Modified Pairs Trading System

3 years, 2 months agoComments closed

pairs-trading tutorial tips

We have modified our pairs trading recommendation system significantly. Here is what you can expect in future:

  • Now expect holding period to be about 15 on average and 25 at maximum. In last few days, many recommendations were sent with unacceptable max holding periods, we have rectified that.
  • Do not expect new pairs recommendations everyday. About 1 new recommendation in every 2 trading days can be expected.


The Techapaisa Team

Exit these pairs

3 years, 2 months agoComments closed

pairs-trading tips

Note: This article is only for premium users of pairs trading recommendations of

We have gone for a complete overhaul of pairs trading system as we were not satisfied with the results. Please exit the following open positions as soon as possible:

  • DLF-IBREALEST (22 Oct 2014)
  • DLF-ASIANPAINT (21 Oct 2014)
  • UNITECH-IBREALEST (20 Oct 2014)
  • DLF-HDIL (20 Oct 2014)
  • NIFTY-AUROPHARMA (09 Oct 2014)
  • JPPOWER-NTPC (09 Oct 2014)
  • GMRINFRA-SIEMENS (07 Oct 2014)
  • BAJAJ-AUTO-EICHERMOT (19 Sep 2014)
  • SIEMENS-BHARATFORG (19 Oct 2014)
  • TATAMOTORS-MRF (16 Sep 2014)
  • NIFTY-MARUTI (05 Sep 2014)
  • LT-BHARATFORG (01 Sep 2014)

We will exit above recommendations at today’s close prices.

Pairs Trading - Frequently Asked Questions

3 years, 6 months agoComments closed

faq pairs-trading

Q: What is pairs trading?

Ans: Pairs trading is a market-neutral strategy where one stock is bought and another is sold simultaneously. Read more here.

Techpaisa has developed a proprietary pairs trading platform where you can test pairs for feasibility for pairs trading free of cost. Check out the platform.

Q: What are pairs trading recommendations?

Ans: Techpaisa provide pairs trading recommendations to its premium users. You can have a look at all old recommendations here.

To understand pairs trading recommendations, please check our tutorial.

Q: How to become a techpaisa’s premium user and get pairs trading recommendations?

Ans: You can get a free trial for 1 week by registering here. After 1 week, service is paid.

Q: Do you send pairs trading recommendations by SMS?

Ans: Right now, pairs trading recommendations are sent over email only and not by SMS. Emails are sent to your registered email-id between 3:00PM and 3:25 PM on every trading day. Note that there might not be a recommendation on a trading day if our trading system does not find any trading opportunity.

Q: How to keep track of live divergence?

Ans: Read our tutorial here.

Q: How much quantity/lots to trade?

Ans: To find the number of future lots to trade for a given pair, you need to login on and visit that particular pairs page. You will find the required information on the pairs page itself.

For example, for pair Sunpharma-Lupin, on this page, it is recommended that For every 3 futures lot of LUPIN, trade 2 futures lot of SUNPHARMA.. That is, if recommendation is Long Sunpharma and Short Lupin, you should buy 2 future lots of Sunpharma and sell 3 future lots of Lupin. If you have spare margin and want to put more money in this trade then you can buy 4 future lots of Sunpharma and sell 6 future lots of Lupin.

Note that on the recommendations page here, quantities are chosen such that total investment in one trade is Rs 2 Lacs. While actually doing trades, you will be trading in future lots and you have to trade such that ratio of quantity remains as stated here.

Q: When trading in futures, future of which expiry date should we trade?

Ans: Consider two points:

  • Liquidity should be reasonable, i.e., volume traded in that futures should be large enough and bid-ask spread should not be big.
  • We mention a maximum holding period in pairs trading recommendation. Decide expiry date based on this number. However, a trade would be closed before the maximum trading days prescribed if target or stop loss divergence is reached.

Remember you would need to roll out open positions to the next expiry if positions are open on an expiry day.

Q: Do you send an intimation to close the trade?

Ans: No. In the recommendation itself, we state the exit condition. A position can be exited under 3 conditions

  • When target divergence is reached or
  • When stop loss divergence is reached or
  • When maximum number of trading days to hold the position have passed.

You have to keep track of live divergence yourself.

Q: How to learn pairs trading?

Ans: Get free trail of techpaisa’s premium service here. Then as you receive live recommendations, do paper trades i.e., don’t place traded with actual money but note them as if you would have done while actually trade. Then follow the trade everyday till it closes.

Q: What are least-risk recommendations?

Ans: Recommendations mentioned as LR (here) are least-risk recommendations where probability of loss is least. If you want to trade selective recommendations, then just trade LR recommendations. Note that it doesn’t mean that other recommendations are risky, we want to provide recommendations for users with lesser margin money to trade who can not trade all recommendations.

Q: Can I trade pairs trading recommendations using stock options?

Ans: Usually, we suggest trading in futures. But you can also trade in options if following is true:

  • As most of the stock options traded on NSE are not that liquid, you must make sure that you are buying or selling an option only if it is liquid.
  • If you want to trade options, then we suggest trading options with delta 1 i.e. in the money options as they behave like futures as long as delta is one.
  • Trade in options only if you know the theory otherwise just trade in futures.

If you have any other query, feel free to mail us at

Good Trading!

Techpaisa Team.

Stay tuned for latest updates:

Understanding Pairs Trading Recommendations

3 years, 10 months agoComments closed

pairs-trading tips

Techpaisa sends exclusive pairs trading recommendations to its premium users. If you want to become premium user, register on and send an email to

We will go over a recommendation by using one example. We sent a recommendation on 19th Feb 2013 of buying NMDC and selling HINDALCO.

Here is the recommendation:
Timeframe: 3months
Entry Threshold: 1.5
Target Divergence: 0
Stop Loss Divergence: -2.5
Current Divergence is: -1.45785
NMDC is trading at 137.25.
HINDALCO is trading at 98.85.

Whenever you receive a recommendation, visit the pair page on For example, in this case, visit NMDC-HINDALCO page.

How to calculate divergence

When doing pairs trading, you should understand what divergence is. (Read our earlier tutorial on pairs trading.) Simply put, divergence is a function of stock prices of constituent stocks in pair. In the above case, divergence is calculated using the folloing formula:

[hindalco_price - (0.8 * nmdc_price) - mean_error]/standard_error

Mean error and standard error are available on pair page.

Here is an explanation of terms:
  • Time frame is 3 months which means divergence is tracked over a period of 3 months.
  • Entry threshold 1.5 means that take positions when divergence is close to 1.5 (or -1.5) and current divergence specifies the exact divergence at which recommendation was given.
  • Target divergence is 0 and stop loss divergence is -2.5.
  • For this trade, it doesn’t make sense to recommend target prices and stop loss prices as we are dealing with a function of two prices. We suggest that on the pairs page, you follow real time divergence regularly and when the real time divergence hits target divergence or stop loss divergence (stated above for this pair), exit positions.
Other things to keep in mind:
  • Take positions around the above prices. When you will do trades, you will be trading in future contracts of above stocks/indices, so the prices you get will be different from above because future contracts trade at certain premium/discount.
  • Hold positions for a maximum of 40 trading days (in this example). This is calculated using half life of pair. Again, since you will be trading future contracts which have an expiry date, so when entering the trade, make sure expiry day is beyond the expected duration of trade which we have stated here.
  • Maximum number of trading days is specified in each recommendations.

Hope this article clears some doubts about the terms used in recommendations. If there is any doubt, feel free to mail us at

Good Trading!

Techpaisa Team.

Stay tuned for latest updates:

Pairs Trading Strategy for Indian Stock Market

6 years, 3 months agoComments closed

pairs-trading tutorial

We are pleased to announce that now you can analyse any pair of stocks using well-known pairs trading strategy at techpaisa. To the best of our knowledge, we are the first website in India to provide this utility online, and free of cost as of now.

What is pairs trading?

As the name suggests, pairs trading strategy works with a pair of stocks. First step is to find a pair of stocks or indices whose prices “move together”. Moving together of price is technically known as cointegration. Idea is to find the pair of stocks which move together but occasionally, this pair will diverge from the average. Whenever a pair diverges from their mean, take positions in both the stocks (one long position and one short position). Gradually, when the prices of these stocks revert to the mean, exit the trades and book profit.

Pairs trading is a market-neutral strategy. A market-neutral strategy means that profit doesn’t depend on the direction of market. As long as the prices of pair of stocks revert to mean, you make money.

How to choose pairs?

First step in pairs trading strategy involves choosing pairs. We suggest you choose stocks from the same sector or subsector. Other pair could be to take one index and choose one of the constituent stocks. Example pairs: SBIN-AXISBANK, AMBUJACEM-ACC. You can also consider two indices as a pair.

At techpaisa, you can do pairs trading here. When you have chosen a pair, use first stock as stock whose market capitalization is more than the second stock. We also give a confidence in statistics of finding pairs, always use pairs with atleast 60% confidence.

How to do pairs trading?

After you have chosen that a pair of stock prices move together, you have to wait for the prices to diverge from their mean. When the prices diverge from their mean, one stock become overvalued and the other undervalued. The bet is that undervalued stock will outperform the overvalued stock and prices will revert to mean. You take long positions in undervalued stock and short positions in overvalued stock. By doing this, your positions become market-neutral (at-least theoretically).

Question is at what divergence, you will take positions, we suggest waiting for a divergence of at least 2 standard deviations from the mean. You can devise your own strategy. We strongly recommend you keep a target and a stop loss for your positions. Keep your target to the point where divergence reverts to 0.5 of standard deviation from mean. Keep your stop loss if divergence becomes 2.5 or 3 times standard deviation from mean.

We backtest pairs trading strategy on historical data to find out optimal entry divergence and stop loss divergence. So for some pairs, you will find that entry divergence is different from +2 or -2.


We will take nifty and banknifty as an example. With 90% confidence, nifty and banknifty prices move together. NIFTY is STOCK1 and BANKNIFTY is STOCK2. Sequence of stocks in a pair matters because based on divergence and sequence of stocks we will determine which stock to long and which stock to short.

In the chart below, prices of nifty and banknifty diverges at 2.01 (standardized error) times the standard deviation from mean. We take positions when standardized error is approaching 2 from above or -2 from below i.e. divergence is decreasing. In the figure below, divergence is approaching -2 from below which means STOCK2 (banknifty in this case) is undervalued (long banknifty) and STOCK1 (nifty) is overvalued.

Standardized Error - Deviation from mean as a multiple of standard deviation

In the chart below, we have the prices of nifty and banknifty.

Nifty and Banknifty price

We take positions on 7th January 2011. Since banknifty is undervalued and nifty is overvalued. We go Long BANKNIFTY and Short NIFTY. Quantities are also decided based on Cointegration Coefficient which we call slope on analysis page. Slope is 3, which means for every 100 stocks in banknifty, trade 300 stocks in nifty. In futures lots, that translates to 3 lots of nifty (150 stocks) and 2 lots of banknifty (50 stocks).

Lets say we buy at the closing price of 7th January 2011 which is Rs. 5904 for NIFTY and Rs. 11053 for BANKNIFTY. We see that prices revert to mean after 7th January 2011 and if we close at our target of 0.5 standard deviation from mean, then that is reached on 24th January 2011. Price on that day is Rs 5743 for NIFTY and Rs. 11151 for BANKNIFTY. Our profit is (5904-5743)150 + (11151-11053)50 which is Rs 29050.

As a general rule, if pair is STOCK1-STOCK2, and entry divergence is negative then LONG STOCK2 - SHORT STOCK1. If entry divergence is positive, LONG STOCK1 - SHORT STOCK2.

You can employ your own strategy for closing trades like you close positions when the standardized error becomes zero i.e. prices revert to the mean exactly.


It may happen that pair of stocks you chose whose prices have diverged might not revert to mean because of a news flow or any other fundamental change in one of the stocks and the statistical relationship doesn’t hold for this pair of stocks anymore.

More links

Techpaisa Team.

DISCLAIMER: If you trade stocks, you do so at your own risk. Trading/Investing in stocks carry high risk. Any trade or action you take in the market is your own responsibility. will not be liable for any loss arising out of the use of any information on the website by anybody.