HestonJ Volatility Surface#
Here we study the Implied volatility surface of the Heston model with jumps. The Heston model is a stochastic volatility model that is widely used in the finance industry to price options.
from quantflow.sp.heston import HestonJ
from quantflow.utils.distributions import DoubleExponential
from quantflow.options.pricer import OptionPricer
pricer = OptionPricer(model=HestonJ.create(
DoubleExponential,
vol=0.5,
kappa=2,
rho=-0.2,
sigma=0.8,
jump_fraction=0.5,
jump_asymmetry=0.2
))
pricer
OptionPricer(model=HestonJ(variance_process=CIR(rate=0.125, kappa=2.0, sigma=0.8, theta=0.125, sample_algo=<SamplingAlgorithm.implicit: 'implicit'>), rho=-0.2, jumps=CompoundPoissonProcess(intensity=100.0, jumps=DoubleExponential(decay=41.5898520668387, loc=0.009681977335121491, kappa=1.2214027581601699))), n=128, max_moneyness_ttm=1.5)
fig = None
for ttm in (0.1, 0.5, 1):
fig = pricer.maturity(ttm).plot(fig=fig, name=f"ttm={ttm}")
fig
pricer.plot3d(max_moneyness_ttm=1.5, support=31).update_layout(
height=800,
title="Heston volatility surface",
)