Rajandran R Telecom Engineer turned Full-time Derivative Trader. Mostly Trading Nifty, Banknifty, USDINR and High Liquid Stock Derivatives. Trading the Markets Since 2006 onwards. Using Market Profile and Orderflow for more than a decade. Designed and published 100+ open source trading systems on various trading tools. Strongly believe that market understanding and robust trading frameworks are the key to the trading success. Writing about Markets, Trading System Design, Market Sentiment, Trading Softwares & Trading Nuances since 2007 onwards. Author of Marketcalls.in)

Long Butterfly Spread – Amibroker AFL code

46 sec read

The Long butterfly spread is a neutral strategy that is a combination of a bull spread and a bear spread. It is a limited profit, limited risk options strategy. There are 3 striking prices involved in a butterfly spread and it can be constructed using calls or puts.

Long Butterfly spread is constructed using Buy 1 ITM Call ,Sell 2 ATM Calls, Buy 1 OTM Call.the long butterfly can be constructed by buying one lower striking in-the-money call, writing two at-the-money calls and buying another higher striking out-of-the-money call. A resulting net debit is taken to enter the trade.

Long Call Butterfly Spread
Butterfly Spread

[wp_ad_camp_5]

 

Payoff Diagram for Long Butterfly Strategy
Long Butterfly

Procedure to Setup Long Butterfly Spread

1.Download Butterfly Spread.afl to Amibroker/Formulas/Options Spread directory
and Unzip the file. Create Options Spread Directory if it doesn’t exist.
2.Open Amibroker->File->Open New Blank Chart
3.Now on the Left Pane goto Charts->Option Spread and drag and drop Bear Iron Condor Spread to the blank chart.
4.Bingo! you got the Spread chart.
5.To Change the spread right click over the charts and goto Parameters where you have control to change the ITM call/put strike A, ATM call/Put Strike B, OTM Call/Put Strike C prices as shown below

Long Butterfly Option Spread Parameters

Supported Strategies
1. Long Call Butterfly
2. Short Call Butterfly

Rajandran R Telecom Engineer turned Full-time Derivative Trader. Mostly Trading Nifty, Banknifty, USDINR and High Liquid Stock Derivatives. Trading the Markets Since 2006 onwards. Using Market Profile and Orderflow for more than a decade. Designed and published 100+ open source trading systems on various trading tools. Strongly believe that market understanding and robust trading frameworks are the key to the trading success. Writing about Markets, Trading System Design, Market Sentiment, Trading Softwares & Trading Nuances since 2007 onwards. Author of Marketcalls.in)

[Live Coding Webinar] Build Your First Trading Bridge for…

In this course, you will be learning to build your own trading bridge using Python. This 60-minute session is perfect for traders, Python enthusiasts,...
Rajandran R
1 min read

[Webinar] Understanding and Mitigating Curve Fitting in System Trading

"Understanding and Mitigating Curve Fitting in System Trading"! This dynamic session aims to equip novice to intermediate traders, quantitative analysts, and financial engineers with...
Rajandran R
1 min read

P-Signal Strategy Long Only Strategy – Amibroker AFL Code

This tutorial provides an overview of the P-Signal reversal strategy, a quantitative trading strategy that utilizes statistical parameters and error functions to generate probabilistic...
Rajandran R
2 min read

2 Replies to “Long Butterfly Spread – Amibroker AFL code”

Leave a Reply

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