• Getting started
    • Steps to get started
    • Subscribe to a paid plan
    • Instructions
    • Pricing
    • Discounted Pro
    • Unlimited Free Plan
    • Customer Support
  • Features (Trade logic)
    • List of all Trading features
    • Entry logic: Entry by Premium
    • Entry logic: ATM %
    • Entry logic: Straddle Width
    • Entry logic: Straddle Premium
    • Entry logic: Percentage of Underlying
    • Entry logic: Specifc Strike
    • Move Stoploss to Cost
    • Positional trades
    • Premium Matching functionality
    • Re-Entry / Re-Cost / Re-Execute
    • Wait & Trade
    • Underlying based Entries & Exits
    • Range Breakout
    • Journey
  • Signals
    • Introduction to Signals
    • Signals: TradingView Pinescript Strategy
    • Signals: TradingView Indicator
    • Signals: Custom Scripts
  • Advanced Settings
    • List of all Advanced Settings
    • Entry order delay & Exit order delay
    • Re-Execute method
    • Re-entry timing settings
    • SL order placement delay
    • Re-entry max count Type
    • Re-execute order delay
    • Entry restriction for next day
    • Target & Stoploss Calculation Method
    • Re-Cost Activation setting
  • Order types
    • Order type: SL-Limit
    • Limit / SL-Limit EXIT orders
    • Limit / SL-Limit ENTRY Orders
  • Other features
    • Square off individual legs
    • Clientwise Stoploss & Target
    • Auto exit on margin error
    • Retry button for individual orders
    • Telegram Notifications
    • Advance placement of Re-Entry orders
    • Multiplier
    • P&L Graph (beta)
    • Next week & Monthly Contracts
    • Underlyings for Strike Selection
    • MTM Setting Increase/Decrease
    • Orderbook
  • Important topics
    • Limit Price Protection (LPP) mechanism
    • BSE Sensex, Bankex & NSE Midcpnifty
    • Lot size revision 2024-25
  • Broker Setup
    • Zebu
    • Dhan
    • Zerodha
    • Indiabulls (XTS)
    • Upstox
    • IIFL
    • IIFL V2 (CDC)
    • Tradejini
    • Tradejini CubePlus
    • Bigul by Bonanza
    • AC Agarwal
    • 5Paisa
    • Kotak Neo (To be discontinued)
    • Jainam Duck
    • Kotak Neo [TOTP]
    • Flattrade
    • Motilal Oswal
    • Fyers
    • Jainam XTS (Retail)
    • MasterTrust
    • AliceBlue
    • Sharekhan

Target & Stoploss Calculation Method


This setting defines the method using which the Target or Stoploss for Individual legs is calculated. It allows you to specify the price to be used to calculate the Target and Stoploss levels for individual legs.

This setting can be found under the Advanced Settings on the algo configuration page.

This setting is applicable only for individual leg target and stoploss price/level calculation only, and NOT applicable for any MTM Target or Stoploss. MTM (Combined Premium) Target or Stoploss will be calculated from average entry price only. 


I. This functionality has 3 setting options:

1. Average Entry Price: This is the default option. With this option the Individual Leg Target price and Individual Leg Stoploss price will be calculated from the average entry price of the leg.

2. Trigger Price: The Trigger Price is considered to be the price at which the entry is set to be triggered and/or the LTP of the symbol at the time the order is placed by the algo. The

Trigger Price method has 2 separate options:

    2.1. Entry At: With this option the Individual Leg Target price and Individual Leg                      Stoploss price will be calculated from the “Entry at” price which is the future price at            which the entry has to trigger, (And NOT the price at which the entry order got filled).            This option works only for strategies where the Wait & Trade feature and/or the Range          Breakout feature is configured. 

    2.2. CRLP + Entry At: CRLP means Common Reference Last Traded Price. This setting is      a combination of CRLP and the above mentioned Entry At price. With this setting, target        and stoplosses for all trades will be calculated from the last traded price (LTP) which is        recorded at the time of placing the order. This means that 2 or more separate algos that      take trades in the same symbols at the same time (same start time) will have the same        common price from which the Target and Stoploss levels will be calculated. 


II. Examples:

Example 1: Entry At

1. Wait & Trade with Average Entry Price (default setting):

In this Wait & Trade example,  SL/TGT Calculation base setting is set to Average Entry Price. Hence the individual leg Target (with setting 5%) and Stoploss (with setting 5%) is calculated from the Average Entry Price for the BUY positions.

Average Entry price: 85.5

Target (+5%):

85.5 + (85.5 x 5%) = 89.77  

= rounded to 89.75

Stoploss (-5%):

85.5 - (85.5 x 5%) = 81.22

= rounded to 81.25

2. Wait & Trade with Entry At:

In this Wait & Trade example,  SL/TGT Calculation base setting is set to Entry At. Hence the individual leg Target (with setting 5%) and Stoploss (with setting 5%) is calculated from the Entry at price for the BUY positions.

Entry at price: 85.45

Target (+5%):

85.45 + (85.45 x 5%) = 89.72  

= rounded to 89.70

Stoploss (-5%):

85.45 - (85.45 x 5%) = 81.17

= rounded to 81.20

Example 2: Entry At

1. Range Breakout with Average Entry Price (default setting):

In this Range Breakout example where the entry is set to trigger at Range High,  the SL/TGT Calculation base setting is set to Average Entry Price. Hence the individual leg Target (with setting 5%) and Stoploss (with setting 5%) is calculated from the Average Entry Price for the BUY positions. 

Average Entry price: 116.4

Target (+5%):

116.4 + (116.4 x 5%) = 122.22

= rounded to 122.20

Stoploss (-5%):

116.4 - (116.4 x 5%) = 110.58

= rounded to 110.60

2. Range Breakout with Entry At:

In this Range Breakout example where the entry is set to trigger at Range High,  the SL/TGT Calculation base setting is set to Entry at. Hence the individual leg Target (with setting 5%) and Stoploss (with setting 5%) is calculated from the Entry at price for the BUY positions. 

Entry at price: 116.3

Target (+5%):

116.3 + (116.3 x 5%) = 122.11

= rounded to 122.10

Stoploss (-5%):

116.3 - (116.3 x 5%) = 110.48

= rounded to 110.50

Other features or combination of features where the ENTRY AT functionality is applicable:

1. ORB & Wait & Trade configured together.

2. Any re-entry type combination that has Wait & Trade, ie. W&T RE COST, W&T RE ENTRY, W&T RE EXECUTE, and many other combinations that include Wait & Trade.

3. Wait & Trade configured in legs configured using the JOURNEY Feature.

Example 3: CRLP + Entry At:

1. Initial entry at Start time:

The LTP at start time is recorded, and the individual leg target and stoploss levels are calculated from this recorded LTP.

Start time LTP price: 100
Average entry price: 98 (Sell trade)
CRLP: 100
Target setting: 20%
Stoploss setting: 10%
Hence,
Calculated Target level will be: 20% - CRLP = 80
Calculated Stoploss level will be 10% + CRLP = 110

2. RE COST: 

The LTP at start time is recorded, and the individual leg target and stoploss levels are calculated from this recorded LTP. This recorded LTP will also be the entry price for all following RE COST type entries, since RE COST type re-entry happens at the initial entry.

LTP at the start time when the initial entry is triggered: 100

Average entry price: 98 (Sell Trade)

CRLP: 100

Target setting: 20%

Stoploss setting: 10%

Hence,
Calculated Target level will be: 20% - CRLP = 80
Calculated Stoploss level will be 10% + CRLP = 110

RE COST Entry 1: 

CRLP of the initial entry will be the entry point ie. 100

Average Entry price: 99 (Sell Trade)

CRLP: 100

Hence,
Calculated Target level will be: 20% - CRLP = 80
Calculated Stoploss level will be 10% + CRLP = 110

RE COST Entry 2: 

CRLP of the initial entry will be the entry point ie. 100

Average Entry price: 98.4 (Sell Trade)

CRLP: 100

Hence,
Calculated Target level will be: 20% - CRLP = 80
Calculated Stoploss level will be 10% + CRLP = 110

3. RE ENTRY: 

The LTP recorded at the start time ie. the CRLP price will also be the entry price for the 1st RE ENTRY type of re-entry. For the following RE ENTRY type re-entries, a new CRLP will be recorded ie. 1st tick price of the next minute after candle close. And that new CRLP will be used to calculate the individual leg target and stoploss.

Initial LTP price at the start time: 100

CRLP: 100

Average entry price: 98 (Sell Trade)

For the 1st RE ENTRY, the previous entry price will be considered as the entry condition trigger, ie. the CRLP price of 100.

RE ENTRY 1:

After Candle Closes below 100, the 1st tick price is 96, RE ENTRY is triggered, average entry price is 95, but individual leg target and stoploss will be calculated from 96 (which is the new CRLP)

RE ENTRY 2:

The previous entry price will trigger the entry condition for the next RE ENTRY. The CRLP of the previous RE ENTRY which was 96. So entry will be triggered if price closes below 96. If it closes at 94, then entry will happen and individual leg target and stoploss will be calculated from 94.

RE ENTRY 3: 

Similarly, the entry trigger level will be 94 for the 3rd RE ENTRY.

4. RE EXECUTE: 

For LTP based RE EXECUTE this setting is NOT APPLICABLE

For CANDLE CLOSE based RE EXECUTE it is applicable. A new CRLP will be recorded ie. 1st tick price of the next minute after candle close when the RE EXECUTE order is fired. And that new CRLP will be used to calculate the individual leg target and stoploss

Example: 

RE EXECUTE trade initiated, the LTP at the time of trade initiation was 50

Average entry price: 49 (Sell Trade)

CRLP: 50

Target setting: 20%

Stoploss setting: 10%

Hence,

Calculated Target level will be: 20% - CRLP = 40

Calculated Stoploss level will be 10% + CRLP = 55


III. USE CASE:

By using the Trigger Price functionality to calculate Target and Stoploss levels for individual legs, there a higher chances that the entries and exits may happen at levels closer to the entry and exits seen in the backtests, hence reducing the deviation between actual trades and the backtest results.

Example scenario:

Price at start time: 100

Wait & Trade entry setting: Sell 2 points ↓ (down)

Hence, calculated 'Entry at' price: 98

Stoploss: 20 points

In this case, the SL as per backtest is 98+20 = 118. In real time execution average entry price may be 97 hence the stoploss would be 117. Now the price may make a high of 117.50 taking out the stoploss in actual execution but the Stoploss is not hit in the backtest. A similar scenario can also play out for Targets. In majority of the cases this deviation can never be favorable, and may create negative divergences when compared to the backtest results in the longer run.