# Option Strategies

### Introduction

Bear put spread, which is also known as short put spread, consists of buying an ITM put and selling an OTM put. Both puts have the same underlying stock and the same expiration date. The OTM put serve as a hedge of the ITM put. It is a option strategy profitting from a decline in underlying asset price.

This is a limited-reward-limited-risk strategy. The payoff is as follows:

$Payoff_{OTM\ put}=(Strike_{OTM\ put}-Price_{underlying})^{+}$

$Payoff_{ITM\ put}=(Strike_{ITM\ put}-Price_{underlying})^{+}$

$Profit/Loss=(Payoff_{ITM\ put}-Payoff_{OTM\ put}+credit\ received_{OTM\ put}-debit\ paid_{ITM\ put})\times multiplier-commissions$

The maximum profit is the spread between the 2 options' strike prices minus net debit paid when opening the trade. If the price is declined and lower than the strike prices of both puts, they will worth $(strike - underlying price) at expiration. Maximum loss is the net debit paid after commission when opening the trade, where is underlying price is above both strike prices and the options become worthless. If the option is American option, there will be a risk of early assignment on the shorted option. ### Implementation Follow these steps to implement the bear put spread strategy. 1. In the Initialize method, set the start date, end date, cash, and Option universe. 2. private Symbol _symbol; public override void Initialize() { SetStartDate(2017, 2, 1); SetEndDate(2017, 3, 5); SetCash(500000); var option = AddOption("GOOG", Resolution.Minute); _symbol = option.Symbol; option.SetFilter(universe => universe.IncludeWeeklys() .Strikes(-15, 15) .Expiration(TimeSpan.FromDays(0), TimeSpan.FromDays(31))); } def Initialize(self) -> None: self.SetStartDate(2017, 2, 1) self.SetEndDate(2017, 3, 5) self.SetCash(500000) option = self.AddOption("GOOG", Resolution.Minute) self.symbol = option.Symbol option.SetFilter(self.UniverseFunc) def UniverseFunc(self, universe: OptionFilterUniverse) -> OptionFilterUniverse: return universe.IncludeWeeklys().Strikes(-15, 15).Expiration(timedelta(0), timedelta(31)) 3. In the OnData method, select the Option contracts. 4. public override void OnData(Slice slice) { if (Portfolio.Invested) return; // Get the OptionChain of the symbol var chain = slice.OptionChains.get(_symbol, null); if (chain.Count() == 0) return; // sorted the optionchain by expiration date and choose the furthest date var expiry = chain.OrderByDescending(x => x.Expiry).First().Expiry; // filter the put options from the contracts which expire on the furthest expiration date in the option chain. var puts = chain.Where(x => x.Expiry == expiry && x.Right == OptionRight.Put); if (puts.Count() == 0) return; // sort the put options with the same expiration date according to their strike price. var putStrikes = puts.Select(x => x.Strike).OrderBy(x => x); // select the strike prices for forming the option legs // the ITM put option with the highest strike price (short) and the OTM put with the lowest strike price (long). var itmStrike = putStrikes.Last(); var otmStrike = putStrikes.First(); def OnData(self, slice: Slice) -> None: # avoid extra orders if self.Portfolio.Invested: return # Get the OptionChain of the self.symbol chain = slice.OptionChains.get(self.symbol, None) if not chain: return # sorted the optionchain by expiration date and choose the furthest date expiry = sorted(chain, key = lambda x: x.Expiry, reverse=True)[0].Expiry # filter the put options from the contracts which expire on the furthest expiration date in the option chain. puts = [i for i in chain if i.Expiry == expiry and i.Right == OptionRight.Put] if len(puts) == 0: return # sort the put options with the same expiration date according to their strike price. put_strikes = sorted([x.Strike for x in puts]) # select the strike prices for forming the option legs # the OTM put option with the lowest strike price (short) and the ITM put with the highest strike price (long). otm_strike = put_strikes[0] itm_strike = put_strikes[-1] 5. In the OnData method, call the OptionStrategies.BearPutSpread method and then submit the order. 6. var optionStrategy = OptionStrategies.BearPutSpread(_symbol, itmStrike, otmStrike, expiry); // We open a position with 1 unit of the option strategy Buy(optionStrategy, 1); } option_strategy = OptionStrategies.BearPutSpread(self.symbol, itm_strike, otm_strike, expiry) # We open a position with 1 unit of the option strategy self.Buy(option_strategy, 1) ### Summary In this algorithm, we've realised the below payout at expiration (2022-3-4). ItemsPrice Price of OTM put$ 4.60
Price of ITM put$40.00 Strike of OTM put$ 767.50
Strike of ITM put$835.00 Price of underlying at expiration$ 829.08
Commission per trade$1.00$Payoff_{OTM\ put}=(767.50-829.08)^{+}=0Payoff_{ITM\ put}=(835.00-829.08)^{+}=5.92Profit/Loss=(5.92-0+4.60-40.00)\times100-1.00\times2=-2950$So, the strategy losses$2950.

### Algorithm

You can also see our Videos. You can also get in touch with us via Discord.