FinancePy

FinancePy API Reference

Fx One Touch Option

financepy.products.fx.fx_one_touch_option

Classes

FXOneTouchOption

FXOneTouchOption(expiry_dt: financepy.utils.date.Date, opt_type: financepy.utils.global_types.TouchOptionTypes, barrier_rate: float, payment_size: float = 1.0)
Inherits from: FXOption
A FinFXOneTouchOption is an option in which the buyer receives one unit of currency if the FX rate touches a barrier at any time before the option expiry date and zero otherwise. The single barrier payoff must define whether the option pays or cancels if the barrier is touched and also when the payment is made (at hit time or option expiry). All of these variants are members of the FinTouchOptionTypes type.

Methods

value

value(self, value_dt: financepy.utils.date.Date, spot_fx_rate: float | numpy.ndarray, domestic_curve: financepy.market.curves.discount_curve.DiscountCurve, foreign_curve: financepy.market.curves.discount_curve.DiscountCurve, model)
FX One-Touch Option valuation using the Black-Scholes model assuming a continuous (American) barrier from value date to expiry. Handles both cash-or-nothing and asset-or-nothing options.

value_mc

value_mc(self, value_dt: financepy.utils.date.Date, stock_price: float, domestic_curve: financepy.market.curves.discount_curve.DiscountCurve, foreign_curve: financepy.market.curves.discount_curve.DiscountCurve, model, num_paths: int = 10000, num_steps_per_year: int = 252, seed: int = 4242)
Touch Option valuation using the Black-Scholes model and Monte Carlo simulation. Accuracy is not great when compared to the analytical result as we only observe the barrier a finite number of times. The convergence is slow.
Generated automatically from the FinancePy source code. Do not edit this file manually.