Binary Barrier Function

Navigation:  Available Functions > Exotic Option Functions > Binary Option Functions >

Binary Barrier Function

Previous pageReturn to chapter overviewNext page

 

The BinaryBarrier function calculates the theoretical price, sensitivities, the implied volatility, and the implied strike value of all 28 different types of European binary barrier options using Reiner and Rubinstein’s model. See Binary Options for a further explanation.

 

 

BinaryBarrier

(OptionType, BarrierType, PayoutType, ModelStatistic, Asset, Strike, Barrier, Payout, TimeExpire, Volatility, InterestRate, YieldRate, MarketPrice, Monitoring, TimePayout, TimeFormat, InterestType, YieldType)

Note: Optional arguments are shown in Italics. MarketPrice is not Optional for the Implied Calculations.

 

 

Argument

Description

OptionType

Alphanumeric value indicating the type of option:

Call = 1 or "c" (case insensitive)

Put = 2 or "p" (case insensitive)

Both = 4 or "b" (case insensitive)

BarrierType

Alphanumeric value indicating the barrier type:

Down_Out = 1 or "do" (Down and Out Barrier)

Down_In = 2 or "di" (Down and In Barrier)

Up_Out = 3 or "uo" (Up and Out Barrier)

Up_In = 4 or "ui" (Up and In Barrier)

PayoutType

Alphanumeric value indicating the type of payout:

Cash_Nothing = 1 or "cn" (case insensitive)

Asset_Nothing = 2 or "an" (case insensitive)

ModelStatistic

Numeric value indicating the type of function required for the return value:

Theoretical = 1

Delta = 2

Gamma = 3

Theta = 4

ImpliedVol = 5

Vega = 6

Rho = 7

Psi = 8

Lambda = 9

StrikeSensitivity = 11

ImpliedStrike = 13

Asset

The price of the underlying asset. Must be > 0.

Strike

The price at which the asset can be purchased if the option is a call or sold if the option is a put. Must be > 0.

Barrier

The barrier price level where the option is either knocked-in or knocked-out.

Payout

The pay out depending on whether the asset price has hit the barrier or not.

TimeExpire

Time, expressed in either Days or Years (depending on the TimeFormat value), until the options expiration. Must be > 0.

Volatility

Annualized volatility of the underlying security. Must be > 0.

InterestRate

Risk-free interest rate expressed as a percentage. This rate is interpreted as a continuously compounded rate unless otherwise specified in the InterestType argument. Must be > 0.

YieldRate

Yield, expressed as a percentage (dividends or interest yield), of the underlying asset price. This rate is interpreted as a continuously compounded rate unless specified otherwise in the YieldType argument.

MarketPrice

Optional. The selling price of the option in the marketplace. This input is required when implied volatility and strike are calculated. Price must be > 0.

Monitoring

Optional. Alphanumeric value indicating the frequency of the barrier monitoring. If omitted, a ContinuousSample is used.

TimePayout

Optional. Alphanumeric value indicating the when the payout occurs. This parameter is only considered when the OptionType is set to both and the Barrier Type is either Up_In or Down_In.  For Down_Out and Up_Out Barriers when TimePayout is set to A_Hit, zero is returned. If omitted, At_Expiration is used as the default. Specified as either:

At_Expiration = 0 or "ae" (case insensitive)

At_Hit = 1 or "at" (case insensitive)

TimeFormat

Optional. Alphanumeric value indicating the format of the time arguments (i.e. TimeExpire). If omitted, Days are used as the default. Specified as either:

Days = 0 or "D" (case insensitive)

Years = 1 or "Y" (case insensitive)

InterestType

Optional. Alphanumeric value indicating the type of InterestRate to use when evaluating the option. This value is converted to Continuously Compounded for the calculations. If omitted, a Continuously Compounded rate is used.

YieldType

Optional. Alphanumeric value indicating the type of YieldRate to use when evaluating the option. This value is converted to Continuously Compounded for the calculations. If omitted, a Continuously Compounded rate is used.

 

 

Example

Calculate all of functions for a up-and-in asset or nothing call option whose asset price 35 days from expiration is $90, the exercise price of the option is $100, the barrier is $92, the rebate is $5, the risk-free interest rate is 8% per annum, the yield rate is 5% per annum, and the annual volatility is 20%. The barrier monitoring is continuous and all of the rates are considered continuous. So,

 

Input

 

Output

Variable

Value

 

Function

Name

Value

OptionType

Call

 

1

Theoretical:

4.676320

BarrierType

4 (Up-and-In)

 

2

Delta:

1.767302

PayoffType

0 (Asset-or-Nothing)

 

3

Gamma:

0.518776

Asset

90

 

4

Theta:

-0.242300

Strike

100

 

5

Implied Vol.:

0.203987

Barrier

92

 

6

Vega:

0.805880

Rebate

5

 

7

Rho:

0.148036

InterestRate

8%

 

8

Psi:

-0.152521

YieldRate

5%

 

9

Lambda:

34.013316

TimeExpire

35

 

11

Strike Sensitivity:

1.543808

Volatility

20%

 

13

Implied Strike:

99.796068

TimeFormat

Days

 

 

 

 

MarketPrice

5

 

 

 

 

 

 

See Also

Asset or Nothing

Cash or Nothing

Two Asset Cash or Nothing

Gap

Supershare

 

 

Remark

For a further example on this model see the included Excel Template located in the root directory of the add-in. This example can be accessed through the Binary Template menu item after the add-in has been installed properly.

 

A list of all of the possible Error Messages is included for convenience.