Strategy Builder

Comprehensive Strategy Development Tool

Overview

Strategy Builder (SB) is a widget which simplifies the creation of strategies including positions which can be a mixture of cash, Options, and underlying asset. Individual positions can be added in the widget to develop and analyze various strategies.

While advanced methods like using Black-Scholes widget together with Position and Strategy widgets exist in OSS, the SB offers a simpler, more user-friendly alternative. It consolidates multiple features into one place, allowing for efficient strategy management. Once the strategy is built, it can be easily exported to other widgets, such as Graph, for detailed analysis and visualization.

A SB widget and some widgets connected to it

Launch the App

Accessing the Widget

The widget can be found in the menu under Options.

SB in the Menu

This widget, like other ones, can simply be searched. you just need to type its abbreviation ("sb") in the search box.

Shortcut

Launch the App

Adding Positions and Their Parameters

As many individual positions cab be added to the Strategy Builder (SB) by clicking on the plus (+) symbol below the last row (see the figure).

Adding Position(s)

Subsequently, the parameters of each position should be entered either manually or through the input interface (inlet). The parameter fields are listed below:

  • Type

  • Underlying Price

  • Expiry

  • Strike

  • Option Price and (Implied) Volatility

  • Side

  • Size

  • Entry Price

Type

In this field the following alternatives can be chosen:

  • Call

  • Put

  • Underlying

  • Cash

Type in SB

The default value for Type is Call.

For Call and Put all parameter fields need to be filled.

For Type Call / Put in SB all the parameters should be filled.

Note that Option Price represents the current price of the contract which, based on the entry or input, can be the mark price, best ask, or best bid price of the market, while the Entry Price represents the average buy or sell price of the contract traded by the user.

For example, you buy a Call Option for $100 and fill that amount in Entry Price and Option Price (supposing that you bought the contract at the mark price). Later, the Price of the contract becomes $105 (now in the field of Option Price). Since your Entry Price is $100 and Option Price is $ 105 your profit would be $5.

If the Entry Price field is left empty and a value is entered into the Option Price field, the entered value will automatically be transferred to the Entry Price field as well.

The field Underlying (Type = Underlying) allows users to represent their positions in spot or futures markets. For example, if you hold 100 shares with an average purchase price of $20 in your portfolio, you can represent them as an Underlying position with Side = Long, Size = 100, and Entry Price = 20. This way you can see the effect of this position in your overall portfolio output as well.

When Underlying is selected, all other non-relevant input fields are automatically deactivated.

For Underlying non-relevant fields are deactivated.

In certain cases, it is possible to add so-called perpetual futures positions to the overall strategy by using Type = Underlying. For example, if there is a short position on a stock with a size of 10 contracts and a leverage of 3 at an average selling price of USD 25, this position can be represented in the strategy as follows: Type = Underlying, Side = Short, Size = 30, Entry Price = 25.

Depending on how many shares correspond to a futures contract and your leverage, you should adjust the Size parameter accordingly. To check it, you can simply connect the outlet of the position individually to the inlet of a graph and monitor how the position's value changes for a one-unit change in the underlying asset.

Alternatively, you can connect the outlet of the position to a data selector widget and check the delta value. This value should correspond to the total leverage of your futures position.

Each position's data can exported out to Data Selector widget.

Cash positions allow you to incorporate positive and negative cash offsets into your strategies. An example of such a use case is the cash-secured put strategy. You can simulate the risk profile of your strategy based on the combination of cash and put positions and examine it in more detail (see figure).

Cash secured put strategy including a cash position

Launch the App

Underlying Price

When trading Options on the spot market, the underlying value of your options refers to the current spot price of the underlying asset. This price remains constant across different option expiries. However, there are situations where the underlying price for certain options may vary.

One example is Options that are based on futures contracts. Since futures contracts have different prices depending on their expiration dates, the underlying prices of options based on them also vary. Another example is trading the same options derived from the same underlying asset but on different spot markets, where slight price differences may exist.

In such cases, it is crucial to consider different underlying prices for each option to ensure accurate calculation of other parameters.

Different underlying prices of the positions

In case there are different underlying prices for different positions in SB, the outcome will be shown separately in the Graph widget connected to the SB. Dashed lines mark the different underlying prices.

Display of the different underlying prices on the graph widget

Launch the App

Expiry

Expiration date of the contract

If the data of the position gets imported via the inlet, this field will automatically be filled according its source, otherwise you should set the Option's expiration date manually by clicking on the calendar symbol or by clicking on the date or time and adjusting it using arrow keys of your keyboard.

The default value for Expiry is set to 30 days in the future.

Launch the App

Strike

The Strike Price of the contract

The strike price of an Option (also known as the exercise price) is the predetermined price at which the Option buyer can buy or sell the underlying asset (such as stocks, commodities, or currencies) when exercising the Option. If the data is imported to the position via its inlet, the field will automatically be filled; otherwise, it must be filled manually.

Launch the App

Option Price and (Implied) Volatility

Option Price and (Implied) Volatility

If Option Price is specified as the input parameter for the position, the volatility is automatically calculated using this price and other input parameters. This volatility, calculated by the Black-Scholes model, is called "implied volatility" (IV). On the other hand, if volatility is specified as the input parameter, it is no longer implied volatility but rather volatility estimated or calculated independently. In this case, the option price is calculated using the Black-Scholes model and the specified volatility as the input parameter.

Option Price as input
Volatility as input
Deactivated fields for Underlying position

Launch the App

Side

The direction or type of position, Long or Short, can be selected in this field. Long is the buy position, and Short is the sell positon.

Size

The Size parameter refers to the number of Options or Futures contracts, or the volume of the underlying asset traded. By default, this parameter is set at 1, so it must be modified manually based on the user's position size.

Launch the App

Entry Price

Entry Price in SB

The Entry Price is the average unit price at which the trade is executed. This entry, basically, should be entered by the user. This price can differ from the current price, i.e., the Option Price when the Type is set to Call or Put, or the Underlying Price when the type is set to Underlying. In other words, the difference between the Entry Price and the current price determines the current unrealized profit or loss of the position.

When a position is fed from another widget through its inlet, the option price is automatically imported into the corresponding field. This can lead to differences in the calculated implied volatility between the widgets. One reason for this is that exchanges often use their own models for calculating option parameters, which can lead to discrepancies. The same applies when the input option is switched to implied volatility: the Option price of the source widget can differ from the option price calculated in the SB (see the figure below).

Launch the App

Feeding the SB

Each position in the Strategy Builder has an receiving socket (Inlet) which is an input interface through which the position's parameters can be fed from outside, i.e., through the outlet of another appropriate widgets (e.g., Option widget or Position widget). The automatically filled parameters of the linked positions remain unchanged and can only be manually changed once the link is unplugged.

The following widgets can be connected to Strategy Builder via its inlet:

Importing Data from Option Chain

It is possible to import the data of a certain Option contract right from the market via Option Chain widget.

This will automatically populate the Option's parameters into the corresponding fields in the position row. This offers the advantage of continuously updating real-time data, such as the Option price.

Choosing a Contract from Option Chain
Selected Contract
Connecting The Option to SB

Please note that when an Option Widget is connected to a position row, the Side, Size, and Entry Price details must still be entered manually.

Launch the App

Black-Scholes and Position Widgets

After creating an Option position using the combination of Black-Scholes and Position widgets, you can link the output of the Position widget to a position row in the SB to automatically transfer all the parameters of your position to the SB. One significant advantage of this method is that if the Black-Scholes or Position Widget themselves are fed with dynamic values from external sources, these parameters are dynamically transferred to the position rows of the SB.

Linking a combined Black-Scholes and Position to a position in the SB

Launch the App

Output Interfaces

SB Output

The top outlet interface of the SB widget is the strategy output interface. Through this interface, all selected (i.e. those whose selection box in the left is checked) data from the combined individual positions are transmitted as a coherent strategy to other suitable widgets such as Graph and Data Selector.

SB Outlet exports its overall data to another widget(s).

Launch the App

Individual Position Output

For each individual position in the SB, an outlet is available, allowing the respective data to be linked out to other suitable widgets.

Individual strategies' data can be transferred out through their own outlets.

Deleting or Deactivating Positions

By deleting a position row in the Strategy Builder, that position is removed from the overall strategy, and all related data is deleted. An alternative way to temporarily disable an individual position is to deactivate it by unchecking the corresponding box to the left of the position row.

Activation / Deactivation vs. Deleting a position

It's important to note that deactivating a position only affects the output of the overall strategy. yet, the position's data remains available at its own outlet and can still be linked with other widgets.

Output of a deactivated position

Launch the App

Scenario Analysis

In the upper part of the widget, various mini-tools for shaping and analyzing scenarios for your strategy can be found.

Underlying Price

To correctly calculate all strategy parameters, a uniform underlying asset price is required for all positions. It's important to note that changes in the underlying asset price can have different effects on the results of calculations, depending on whether Option Price or Volatility was set as input parameters for all positions.

For example, if you want to examine the impact of changes in the Underlying Price on the Option prices in the positions, you should have Option Price as the output and Volatility as the (constant) input. This takes changes in the underlying asset price into account while considering volatility as constant, and the Option price is calculated based on these parameters.

Volatility as input for examining the impact of change in UP on Option Price

Conversely, by setting Option Price as the (constant) input, you can examine the effects of changes in the Underlying Price on the Implied Volatility.

Option Price as input for examining the impact of change in UP on IV

To dynamically adjust the underlying asset price, you can use a Numeric Slider Widget and link it to the input of Underlying Price.

Launch the App

Analyzing Volatility Changes

The impact of changes in volatility on the strategy can be easily and quickly examined using the Volatility (% change) slider.

The Strategy Builder widget includes a Volatility Adjustment feature that allows users to see how changes in implied volatility affect their overall strategy. By using the volatility slider, located in the upper part of the widget, users can adjust the implied volatility percentage. Moving the Volatility Slider makes the IV of all Option positions in the widget change between -99% (near-zero volatility) and 100% (twice the current value). Simultaneously, the Option prices for each position are calculated based on the new input parameters and displayed as output. This effect is best visualized using the Graph Widget.

Examining the impacts of IV change on the Strategy is as simple as moving the slider.

It's important to note that even if the parameters of a position are supplied from external widget(s), changing implied volatility by the slider makes recalculation in the option price.

The refresh button in the Volatility slider resets the implied volatility changes back to zero, restoring all values to their original state.

Resetting th IV changes

By clicking the slider once, you can subsequently make the smallest tick of change, namely 1%, using the up (∧) and down (∨) symbols, or the arrow keys on your keyboard.

Volatility Slider

Launch the App

Changing Days Till Expiry

Days Till Expiry Slider in SB

By the Days till expiry slider, the number of days remaining until the Option's expiry date can be manually changed. This way, the changes in other parameters can be examined as the number of days till expiry changes.

The current date of the slider, known as the Valuation Date, is the date and time at which the current Option prices and the current unrealized profit or loss of the positions in a strategy are determined. The default value for the Valuation Date is the current date and time.

Changin Number of Days to Expiry to Examine its impacts on the strategy

The difference between the Valuation Date and the Expiry (Days till Expiry) is one of the input parameters of the Black-Scholes model for calculating option prices. This number is displayed under the slider as (xxx d xx h)

The farthest date on the slider is automatically set and cannot be adjusted manually. This date is determined by the earliest expiration date among the selected options in the positions within the strategy.

If one of the positions in the widget is disabled (by unchecking the box at its right side) then the expiry of that position is excluded from the calculation of the slider.

The earliest date on the slider can be manually set using the calendar symbol.

Valuation Date can also be manually changed by clicking on the calendar symbol below the slider. This will open a calendar that allows you to set the date and time.

Using the Reset symbol the changes can simply be undone.

By clicking the slider once, you can subsequently make the smallest tick of change, which is 1 day, using the arrow keys on your keyboard.

Launch the App

Some Errors in SB

Input Fields

As with all other widgets, red-framed fields indicate that they need to be filled in for the widget to calculate its outputs correctly.

Input fields

Error Message in Minimized State

If you notice an error message on the minimized widget, it means that an error or warning message has occurred in the widget. To identify and resolve the widget needs to be opened.

Error on Minimized Widget

Launch the App

Last updated