Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 39 additions & 13 deletions examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ Samples are grouped by API area. Each `.md` file contains one or more Python sni
| [**margins/**](margins/) | Margin details. |
| [**charges/**](charges/) | Brokerage details. |
| [**trade-profit-and-loss/**](trade-profit-and-loss/) | P&L report, report metadata, trade charges. |
| [**strategies/**](strategies/) | Ready-to-run options strategy examples for Nifty 50 (bullish, bearish, neutral). |
| [**strategies/**](strategies/) | Ready-to-run options strategy examples for Nifty 50 (bullish, bearish, neutral, others). |

### Options Strategies

Expand All @@ -48,28 +48,54 @@ Each strategy script searches for the required Nifty 50 option legs using the In

| File | Strategy | Legs |
|------|----------|------|
| [buy_call.py](strategies/bullish/buy_call.py) | **Buy Call** | BUY ATM CE |
| [sell_put.py](strategies/bullish/sell_put.py) | **Sell Put** | SELL ATM PE |
| [bull_call_spread.py](strategies/bullish/bull_call_spread.py) | **Bull Call Spread** | BUY ATM CE + SELL ATM+1 CE |
| [bull_put_spread.py](strategies/bullish/bull_put_spread.py) | **Bull Put Spread** | SELL ATM PE + BUY ATM-1 PE |
| [buy_call.py](strategies/bullish/code/buy_call.py) | **Buy Call** | BUY ATM CE |
| [sell_put.py](strategies/bullish/code/sell_put.py) | **Sell Put** | SELL ATM PE |
| [bull_call_spread.py](strategies/bullish/code/bull_call_spread.py) | **Bull Call Spread** | BUY ATM CE + SELL ATM+1 CE |
| [bull_put_spread.py](strategies/bullish/code/bull_put_spread.py) | **Bull Put Spread** | SELL ATM PE + BUY ATM-1 PE |
| [bull_butterfly.py](strategies/bullish/code/bull_butterfly.py) | **Bull Butterfly** | BUY ATM CE + SELL 2× ATM+1 CE + BUY ATM+2 CE |
| [bull_condor.py](strategies/bullish/code/bull_condor.py) | **Bull Condor** | BUY ATM CE + SELL ATM+1 CE + SELL ATM+2 CE + BUY ATM+3 CE |
| [long_calendar_call.py](strategies/bullish/code/long_calendar_call.py) | **Long Calendar with Calls** | SELL current-week ATM CE + BUY next-week ATM CE |
| [long_synthetic_future.py](strategies/bullish/code/long_synthetic_future.py) | **Long Synthetic Future** | BUY ATM CE + SELL ATM PE |
| [call_ratio_back_spread.py](strategies/bullish/code/call_ratio_back_spread.py) | **Call Ratio Back Spread** | SELL 1× ATM CE + BUY 2× ATM+1 CE |
| [range_forward.py](strategies/bullish/code/range_forward.py) | **Range Forward** | SELL ATM-1 PE + BUY ATM+1 CE |

#### [Bearish](strategies/bearish/)

| File | Strategy | Legs |
|------|----------|------|
| [buy_put.py](strategies/bearish/buy_put.py) | **Buy Put** | BUY ATM PE |
| [sell_call.py](strategies/bearish/sell_call.py) | **Sell Call** | SELL ATM CE |
| [bear_call_spread.py](strategies/bearish/bear_call_spread.py) | **Bear Call Spread** | SELL ATM CE + BUY ATM+1 CE |
| [bear_put_spread.py](strategies/bearish/bear_put_spread.py) | **Bear Put Spread** | BUY ATM PE + SELL ATM-1 PE |
| [buy_put.py](strategies/bearish/code/buy_put.py) | **Buy Put** | BUY ATM PE |
| [sell_call.py](strategies/bearish/code/sell_call.py) | **Sell Call** | SELL ATM CE |
| [bear_call_spread.py](strategies/bearish/code/bear_call_spread.py) | **Bear Call Spread** | SELL ATM CE + BUY ATM+1 CE |
| [bear_put_spread.py](strategies/bearish/code/bear_put_spread.py) | **Bear Put Spread** | BUY ATM PE + SELL ATM-1 PE |
| [bear_butterfly.py](strategies/bearish/code/bear_butterfly.py) | **Bear Butterfly** | BUY ATM PE + SELL 2× ATM-1 PE + BUY ATM-2 PE |
| [bear_condor.py](strategies/bearish/code/bear_condor.py) | **Bear Condor** | BUY ATM PE + SELL ATM-1 PE + SELL ATM-2 PE + BUY ATM-3 PE |
| [long_calendar_put.py](strategies/bearish/code/long_calendar_put.py) | **Long Calendar with Puts** | SELL current-week ATM PE + BUY next-week ATM PE |
| [short_synthetic_future.py](strategies/bearish/code/short_synthetic_future.py) | **Short Synthetic Future** | SELL ATM CE + BUY ATM PE |
| [put_ratio_back_spread.py](strategies/bearish/code/put_ratio_back_spread.py) | **Put Ratio Back Spread** | SELL 1× ATM PE + BUY 2× ATM-1 PE |
| [risk_reversal.py](strategies/bearish/code/risk_reversal.py) | **Risk Reversal** | SELL ATM+1 CE + BUY ATM-1 PE |

#### [Neutral](strategies/neutral/)

| File | Strategy | Legs |
|------|----------|------|
| [short_straddle.py](strategies/neutral/short_straddle.py) | **Short Straddle** | SELL ATM CE + SELL ATM PE |
| [short_strangle.py](strategies/neutral/short_strangle.py) | **Short Strangle** | SELL ATM+1 CE + SELL ATM-1 PE |
| [iron_butterfly.py](strategies/neutral/iron_butterfly.py) | **Iron Butterfly** | SELL ATM CE + SELL ATM PE + BUY ATM+2 CE + BUY ATM-2 PE |
| [batman.py](strategies/neutral/batman.py) | **Batman** | BUY ATM CE + SELL 2× ATM+1 CE + BUY ATM+2 CE + BUY ATM PE + SELL 2× ATM-1 PE + BUY ATM-2 PE |
| [short_straddle.py](strategies/neutral/code/short_straddle.py) | **Short Straddle** | SELL ATM CE + SELL ATM PE |
| [short_strangle.py](strategies/neutral/code/short_strangle.py) | **Short Strangle** | SELL ATM+1 CE + SELL ATM-1 PE |
| [iron_butterfly.py](strategies/neutral/code/iron_butterfly.py) | **Iron Butterfly** | SELL ATM CE + SELL ATM PE + BUY ATM+2 CE + BUY ATM-2 PE |
| [batman.py](strategies/neutral/code/batman.py) | **Batman** | BUY ATM CE + SELL 2× ATM+1 CE + BUY ATM+2 CE + BUY ATM PE + SELL 2× ATM-1 PE + BUY ATM-2 PE |
| [short_iron_condor.py](strategies/neutral/code/short_iron_condor.py) | **Short Iron Condor** | SELL ATM+1 CE + BUY ATM+2 CE + SELL ATM-1 PE + BUY ATM-2 PE |

#### [Others](strategies/others/)

| File | Strategy | Legs |
|------|----------|------|
| [long_straddle.py](strategies/others/code/long_straddle.py) | **Long Straddle** | BUY ATM CE + BUY ATM PE |
| [long_strangle.py](strategies/others/code/long_strangle.py) | **Long Strangle** | BUY ATM+1 CE + BUY ATM-1 PE |
| [call_ratio_spread.py](strategies/others/code/call_ratio_spread.py) | **Call Ratio Spread** | BUY 1× ATM CE + SELL 2× ATM+1 CE |
| [put_ratio_spread.py](strategies/others/code/put_ratio_spread.py) | **Put Ratio Spread** | BUY 1× ATM PE + SELL 2× ATM-1 PE |
| [long_iron_butterfly.py](strategies/others/code/long_iron_butterfly.py) | **Long Iron Butterfly** | BUY ATM CE + BUY ATM PE + SELL ATM+2 CE + SELL ATM-2 PE |
| [long_iron_condor.py](strategies/others/code/long_iron_condor.py) | **Long Iron Condor** | BUY ATM+1 CE + SELL ATM+2 CE + BUY ATM-1 PE + SELL ATM-2 PE |
| [strip.py](strategies/others/code/strip.py) | **Strip** | BUY 1× ATM CE + BUY 2× ATM PE |
| [strap.py](strategies/others/code/strap.py) | **Strap** | BUY 2× ATM CE + BUY 1× ATM PE |

## Documentation

Expand Down
Loading