instruction
stringlengths
15
26.1k
Under certain conditions, the option price of the CRR (Cox-Ross-Rubinstein) Binomial model converges to the Black-Scholes price as the maximal step size of the partition converges to zero (i.e. a smoother partition of $\left[0,T\right]$ is taken). What are these conditions? Does the same convergence can be observed...
I'm confused a bit with the following problem: As far as i understand, the following problem where $$\min_{w} \omega^{T}\Sigma\omega$$ $$\textrm{s.t.}\hspace{0.5cm} \omega^{T}\mu=E$$ $$ \omega^{T}\textbf{1}=1 $$ yields the analytical solution $$w^{*}=\frac{\Sigma^{-1}\mu}{1'\Sigma^{-1}\mu} $$ where $w$ re...
Suppose I know or have estimated the covariance matrix for one random variable (for example an asset) and have: $$ \begin{bmatrix} <\text{spot, spot}> & <\text{atmv, spot}> \\ <\text{spot, atmv}> & <\text{atmv, atmv}> \end{bmatrix} $$ where atmv is the at the money volatility (or can just be realized). Suppo...
I am looking to perform a geometric Brinson type attribution that is able to separate out the effects of underweights and overweight's of individual securities and groups individually. From an allocation standpoint, this is relatively easy as an overweight/underweight allocations to groups can be determined relative...
$return(b)=cor_{A,B}*return(A)+noise_1$ so $return(b)=cor_{A,B}*(beta_{A,vol}*atmvol+noise_2)+noise_1$ so the correlation between b and atm vol depends on the correlation assumption between atmvol and noise_1. So there's no right answer if you have to go through A. Why don't you just directly correlate atmvol a...
I'm creating a pricing model for an asset that is similar to a bond, but there are some quirks that I'm unsure how to work out. The asset is a tax lien, in which delinquent tax bills (usually on property taxes) are sold at auction to private investors, who then pay the subsequent tax bills on the property, charging int...
When trying to forecast time series, say forecasting the level of a stock index so we can forecast the future values of an option, it tends to be helpful to analyze the log returns versus the original levels as these are additive across time, can be more numerically stable, etc. Assuming that we try to predict the c...
When deriving the rough Bergomi model, Bayer et al perform a change of measure to ensure the price process is a martingale. https://papers.ssrn.com/sol3/papers.cfm?abstract_id=2554754 However, there is recent academic work showing that the process is a local martingale and a true martingale under certain conditi...
I am curious about the current standard conventions and modeling techniques in the CDS options market. I would be glad if someone could elaborate on the following topics: 1) State of the art of index CDS option pricing (Valuing front end protection etc). Is there any consensus in the interbank market on how the pric...
When deriving the rough Bergomi model, Bayer et al in "[Pricing Under Rough Volatility](https://papers.ssrn.com/sol3/papers.cfm?abstract_id=2554754)" (2015) perform a change of measure to ensure the price process is a martingale as shown in the screenshot below: [![Bayer change of measure][1]][1] However, there ...
Perhaps this type of question is not very suitable for this forum, but I'll try to make my question a little useful. I'm studying stochastic processes, more precisely, Levy processes. A Levy process $X=(X_t)_{t\geq 0}$ is characterized by its characteristic function given by: $$\log \varphi_{X_t}(u)= t\left(ib'u+ \...
I am trying to get past 10 years P&L data for a bunch of Indian companies, but can't seem to find a good API to do so. I have tried yfinance, Alpha Vantage, IEX cloud and a few others. I tried web scraping certain websites but they always have some sort of rate limiter. Does anyone know of a good API that I can use for...
[![enter image description here][1]][1] [1]: https://i.stack.imgur.com/euXzQ.png Hello guys, starting from this picture, which is the method that you usually use in order to find Zero Rate from Discount Factor? Thank you in advance
Does anyone know where I can find this information?
Get a list (csv) of All European ADR tickers trading on NASDAQ and NYSE and the symbol of the associated parent tickers?
1) Do payments maturing on holidays and rolled to the next business day affect the calculation of accrued interests and yields? 2) Can there be payments or weekends or holidays? Is that more unusual in floating-rate bonds? 3) In some markets, the YTM is computed on an actual/365 basis. Are the theoretical payment...
Do bond payments maturing on non-business days and rolled to the next business day affect the calculation of accrued interests and yields?
1) Do payments maturing on holidays and rolled to the next business day affect the calculation of accrued interests and yields? 2) Can there be payments or weekends or holidays? Is that more unusual in floating-rate bonds? 3) In some markets, the YTM is computed on an actual/365 basis. Are the theoretical payment...
I am trying to solve this question: *Write down pseudocode to learn a local stochastic volatility for finitely many given option prices: assume a Heston stochastic variance and parametrize local volatility by a neural network and solve the pricing equation by an Euler scheme, then define a loss function and write...
When trying to recreate this chart from Deutsche on contribution to compound returns of an asset class I'm using log returns of each percentile group (bottom, mid, top), take the sum and divide each of them by the sum of the full return series. I don't know how to get from there to this chart or if that's even the ...
Was looking at some sourced data and noticed that a 4 year annualized default probability was greater than a 5 year annualized default probability. This seems counter intuitive even in the case that most of their debt is in the short term with expectations of large positive cashflows in the mid/long term. Is it possibl...
I'm creating a pricing model for an asset that is similar to a bond, for which I need a discount rate. Using yield to calculate this discount rate was my first thought, but this seems impossible for reasons I will outline. The asset is a tax lien, in which delinquent tax bills (usually on property taxes) are sold at...
I have the following exercise: A financial security pays off a dollar amount of $S_T^2$. Using Ito`s Lemma, what is the price today $V_t$ of this security? (S follows a Geometric Brownian Motion $dS = \mu Sdt + \sigma S dB$ ) I know that $V_t = e^{-r(T-t)}E^Q[V_T]$. So I tried to calculate $E^Q[V_T]$ with Ito`s Lemm...
I have a question regarding hypothesis testing. I used the t-test (2-tailed) for these hypotheses: 1. Whether the (monthly) mean return of company A's stock is different from 0 2. Whether the (monthly) mean return of S&P500 is different from 0 3. Whether the (monthly) mean return of company A's stock is differe...
Hypothesis Test Contradiction?
Local volatility (LV) must be positive. The expression for LV in vol space can be found [here][1] on page 10. [1]: https://citeseerx.ist.psu.edu/document?repid=rep1&type=pdf&doi=4f135a80c3b17bb838d6dde7873ecc58c69aa6bd
Say I have historical data of a ticker for the past 5 years. I look at the price on the current date for each of the five years (e.g. today is 20 Jul 2023 so I will look at 20 Jul 2022, etc.) and then consider the returns for 3 months (60-80 business days) from that day. Can I use this as the sample space to determi...
I'm pretty new to all this but haven't found anything online on my issue (the answer may be very obvious since I'm a beginner) - I'm currently coding up a very generic orderbook in C++ for fun, just matching bids to asks at the moment - I was wondering if there was a way to test my code on real orderbook data. I took a...
I need some guidance on valuing American style FX options (spots and forwards) using quantlib in Python. Given the following parameters: 1. Domestic and foreign risk-free rates 2. Current market spot and forward points for the underlying asset (maturity at option exercise date plus tenor) - as an aside, does the matu...
Is there an analytical formula to approximate the discounted exposure for a European Put on a Stock in the Real-World measure? This is just an initial phase to be able to assess the accuracy of using Longstaff-Schwartz regression method, using a simple example. I would like to compare the regression results with analyt...
Is there an analytical formula to approximate the discounted exposure for a European Put on a Stock in the Real-World measure? This is just an initial phase to be able to assess the accuracy of using Longstaff-Schwartz regression method, using a simple example. I would like to compare the regression results with analyt...
Is there an analytical formula to approximate the discounted exposure for a European Put on a Stock in the Real-World measure? This is just an initial phase to be able to assess the accuracy of using Longstaff-Schwartz regression method, using a simple example. I would like to compare the regression results with analyt...
Is there an analytical formula to approximate the discounted exposure for a European Put on a Stock in the Real-World measure? This is just an initial phase to be able to assess the accuracy of using Longstaff-Schwartz regression method, using a simple example. I would like to compare the regression results with analyt...
I would like to try to replicate this variance dummied model in r studio, to try to compare garch vs i.v in forecasting vol: Data : S&P 500 log-return from 03.01.2020 to 31.12.2022 Ext regressor : Vix from 03.01.2020 to 31.12.2022. [![enter image description here][1]][1] [![enter image description here][2]][2...
I use the Black Scholes Merton model from Quantlib to calculate call options and its Greeks. But my numerical Greeks (Theta, Vega) do not match with Quantlib's output. Does anyone know what went wrong with my implementation? Thanks. ``` import numpy as np import pandas as pd import QuantLib as ql def cal...
Why my options' Theta and Vega do not match on PyQuantlib?
Quantlib BSM's Greeks do not match with its Numerical Greeks?
I use the Black Scholes Merton (BSM) model from Quantlib to calculate call options and its Greeks. I also calculate the Greeks (Theta, Vega) using numerical methods, but they do not match with the BSM's output. Does anyone know what went wrong with my implementation? Thanks. ``` import numpy as np import pandas as...
There are many academic sources, books and articles, introducing forward interest rate curve. For example, those authors define $f(\tau)=f(\tau;\beta_0,\beta_1,\beta_2,\lambda)$ as a function of time to maturity $\tau$, dependent on parameters to be estimated. Such approach is use while introducing, e.g., Nelson-Siegel...
I'm pretty new to all this but haven't found anything online on my issue (the answer may be very obvious since I'm a beginner) - I'm currently coding up a very generic orderbook in C++ for fun, just matching bids to asks at the moment - I was wondering if there was a way to test my code on real orderbook data. I took a...
The put price at any point in the future $t$, with stock price $S(t)$, is just $BS(T-t,S(t),K)$, i.e. the black-scholes price. In american options context the "continuation value" is always the black-scholes price. This is the value I would want the longstaff algorithm to be able to approximate. The expected stock p...
Technical Analysis Indicators as input of a LSTM Neural Network ? Need advices
Crowdsource question: What is your preferred API/source for historic futures (ES) options pricing data and if possible, the Greeks? We are working on a model relating economic data and the impact on options prices, particularly the Greeks. While I am comfortable with the sources I am using for fundamental and ec...
What is your preferred API/source for historic futures (ES) options pricing data and if possible, the Greeks?
I use the Black Scholes Merton (BSM) model from Quantlib to calculate call options and its Greeks. I also calculate the Greeks (Theta, Vega) using numerical methods, but they do not match with the BSM's output. Does anyone know what went wrong with my implementation? Thanks. ``` import numpy as np import pandas as...
I use the Black Scholes Merton (BSM) model from Quantlib to calculate Call options price and its analytical Greeks. I also manually calculate its Numerical Greeks (Theta, Vega), but the results do not match. Does anyone know what went wrong with my implementation? Thanks. ```python import numpy as np import pandas...
Quantlib's BSM Analytical Greeks do not match with its Numerical Greeks?
I use the Black Scholes Merton (BSM) model from Quantlib to calculate Call options price and its analytical Greeks. I also manually calculate its Numerical Greeks (Theta, Vega), but the results do not match. Does anyone know what went wrong with my implementation? Thanks. ```python import numpy as np import pandas...
QuantLib: Analytical Greeks and Numerical Greeks do not match?
I use the Black Scholes Merton (BSM) model from QuantLib to calculate Call options price and its analytical Greeks. I also manually calculate its Numerical Greeks (**Theta, Vega**), but the results do not match. Does anyone know what went wrong with my implementation? Thanks. ```python import numpy as np import pa...
Crowdsource question: What is your preferred API/source for historic futures (ES) options pricing data and if possible, the Greeks? We are working on a model relating economic data and the impact on options prices, particularly the Greeks. While I am comfortable with the sources I use for fundamental and economi...
I use the Black Scholes Merton (BSM) model from QuantLib to calculate Call options price and its analytical Greeks. I also manually calculate its Numerical Greeks (**Theta, Vega**), but the results do not match. Does anyone know what went wrong with my implementation? Thanks. ```python import numpy as np import pa...
I use the Black Scholes Merton (BSM) model from QuantLib to calculate Call options price and its analytical Greeks. I also manually calculate its Numerical Greeks (**Theta, Vega**), but the results do not match. Does anyone know what went wrong with my implementation? Thanks. ```python import numpy as np import pa...
I use the Black Scholes Merton (BSM) model from QuantLib to calculate Call options price and its analytical Greeks. I also manually calculate its Numerical Greeks (**Theta, Vega**), but the results do not match. Does anyone know what went wrong with my implementation? Thanks. ```python import numpy as np import pa...
I use the Black Scholes Merton (BSM) model from QuantLib to calculate Call options price and its analytical Greeks. I also manually calculate its Numerical Greeks (**Theta, Vega**), but the results do not match. Does anyone know what went wrong with my implementation? Thanks. ```python import numpy as np import pa...
For single-curve RFR bootstrapping, such as a SOFR-based discounting curve bootstrapped strictly using SOFR fixed-float OIS, I am trying to understand if convexity adjustments are technically necessary in the bootstrapping process to calculate the present values of the OIS coupons due to the payment lag (delay after th...
I was recently learning about value at risk and how to calculate it, and one of the steps was to calculate the covariance of the returns of the securities making up the portofolio. This makes sense because if we consider the return of the securities as random variables ( and dont assume independence between them ) and...
Why do we need the covariance when calculating VaR?
Why do we need the covariance when calculating portfolio VaR?
I think this is a fairly basic question but I'm struggling to understand the no-arbitrage principle applied to CCR. Imagine that we want to calculate the exposure evolution in an IR derivative, comparing risk-neutral vs real-world probabilities. We will have two different profiles that have the same value on the day...
I hope you are doing well. As part of my thesis, I built 12 portfolios of 200 randomly selected stocks. I now want to calculate the Bs of the 3 Fama French factors for each stock, so that I can average them for a time T and calculate the expected return on my portfolio at time T. I have therefore constructed the HML ...
Consider the reserve price from the algorithm: $$ r(s, t) = s - q\gamma \sigma^2(T-t) $$ where $s$ is the initial value of mid-price on the market, $q$ is a number of stocks that trader has, $\gamma$ is a risk aversion parameter, $T$ is time till trader holds his assets. Also consider reserve bid and ask prices, wh...
So this "SOFR vs fixed" swap has a fixed leg paying 5.231% yearly and a floating leg paying yearly the yearly compounded SOFR rate, and has a 1W term. If it has started today, it won't have any cashflows exchanged as 1W < 1Y. So necessarily it is a swap having started earlier but then, which swap is it ? [![enter im...
What could the cashflows of US0SFR1Z Curncy be?
In the stackexchange answer [Change of numeraire in options with currency exchange features][1] >Pratically speaking, what this expresses is that these two things are the same: Converting the payoff (which is in EUR) to COP at T and then discounting in COP from T to t; Discounting the payoff from T to t in...
(1) Do theoretical payment dates falling on holidays and being moved (bumped) to the next or previous business day affect the computation of the coupon amount and the accrued interests within the coupon period? In other words, are the `adjusted` (bumped) or the `unadjusted` (unbumped) payment days used in the calculati...
Do bond payments falling on non-business days and moved to the next or previous business day affect the calculation of accrued interest and YTM?
(1) Does the rolling of theoretical payment dates falling on holidays to the next or previous business day affect the coupon payment and the accrued interests within the coupon period? In other words, are the `adjusted` (bumped) or the `unadjusted` (unbumped) payment days used in the calculations? (2) Is there a cor...
I need some guidance on valuing American style FX options (spots and forwards) using quantlib in Python. Given the following parameters: 1. Domestic and foreign risk-free rates 2. Current market spot and forward points for the underlying asset (maturity at option exercise date plus tenor) - as an aside, does the matu...
I need some guidance on valuing American style FX options (spots and forwards) using quantlib in Python. Given the following parameters: 1. Domestic and foreign risk-free rates 2. Current market spot and forward points for the underlying asset (maturity at option exercise date plus tenor) - as an aside, does the matu...
Crowdsource question: What is your preferred API/source for historic futures (ES) options pricing data for the greeks? (NOTE: Over ten years ago, there was a similar question with several suggestions, mostly with fundamental and stock info, and none of these answers included futures data for options or Greeks data. ...
I am following a course about portfolio construction with Python. I am able to successfully draw the efficient frontier and capital market line (CML), and the global minimum variance (GMV) point using daily returns of different assets. However, when I try to lower the frequency to 15 minutes or 5 minutes, the CML (gree...
Can anyone help me to understand why the GMV point is not on the efficient frontier?
Currently looking at yield curves, specifically SOFR OIS Curves, and I'm struggling to find a good explanation between a zero-coupon OIS curve and an annual coupon-pay OIS curve (both SOFR). When would one want to use a zero-coupon variety and when would want to use the coupon-pay type? For reference, on Refinitiv, ...
In practice is it possible to enter into a par par asset swap where the bond is purchased from counterparty A and the swap element is conducted with counterparty B?
I have a piece of daily volume and a piece of daily trades data, now I divide them and I get volume/trades as a factor. This factor has positive value and I want it to be normalized to predict the next-day return by its sign. My solution is to revise the factor as ``` factor = factor - factor.rolling.mean(window)```. ...
A delta-hedging principle involves taking the opposite direction, i.e., short and long, to hedge against financial risk. An example is **longing** an option call and selling (**shorting**) the borrowed the delta amount of the underlying assets. If the asset price rises, we can make a profit by exercising the option....
Now we can place orders in pre-market trading hours, from 4 am to 9:30 am. And then we go into standard trading hours, 9:30 am to 4:30 pm. But I wonder then when will the Market Order Auction happen? According to this doc: https://www.nyse.com/markets/nyse-arca/market-info, there will be a market order freeze period...
What happened when market status change from pre-market trading hours to standard trading hours?
I am creating a backtest using vectorbt library. This is my function for all the portfolio metrics: ``` pf = vbt.Portfolio.from_signals( signal_data['close'], entries, exits, init_cash=10_000_000, freq='D' ) ``` Now, instead of using the close price I want to switch to bid and ask pric...
Given a set of greeks (delta, gamma, theta, vanna, volga, vega, rho) and other information such as the dividend rate, dividend forecast, and realized volatility for American or European Options but no IV. What's the best way to approximate IV given this set of information? I'm aware of the Volga-Vanna method but are...
I have some experience trading both sides of an order book, but not simultaneously in the same security (and certainly not at the size large market makers do.) I've searched pretty extensively for books on the topic, but there isn't really a "strategies for market makers" type of textbook out there in something lik...
Where can I learn more about market-making strategies?
(1) Does the rolling of theoretical payment dates falling on holidays to the next or previous business day affect the coupon payment and the accrued interests within the coupon period? In other words, are the `adjusted` (bumped) or the `unadjusted` (unbumped) payment days used in the calculations? (2) Is there a cor...
How is the price of US T-Bill's calculated here on CNBC?
The hypothesis that I am mulling over (and more so, its effect on stock price movement) is the following. **Hypothesis:** Buyers of options do not hedge (as they don't need to) while sellers usually hedge in some form or the other. If that is true, what happens is that if buyers of stock keep buying, and spot p...
I would like to expand my knowledge on systematic strategies in fixed income. I know there are a lot of articles on equity but these markets are different and I would like to know more. Are there good summary books or summary papers? Mainly interested in corp bonds, options, FX.
(1) Does the rolling of bond payment from non-business days to the next or previous business day affect the coupon payment and the accrued interests within the coupon period? In other words, are the `adjusted` (bumped) or the `unadjusted` (unbumped) payment days used in the calculations? (2) Is there a correspondenc...
Does the rolling of bond payments from non-business days to the next or previous business day affect the calculation of accrued interest and YTM?
I'm looking for numerical examples on how CME SOFR futures contracts are used in practice for hedging purposes. Book references containing this discussion are appreciated. Bloomberg's FLDS function gives 0.25 as the duration for all maturities. What's the reasoning behind this?
I'm looking for numerical examples on how CME SOFR futures contracts are used in practice for hedging purposes. Book references containing this discussion are appreciated. Bloomberg's FLDS function gives 0.25 as the contract duration for all maturities. What's the reasoning behind this?
I am trying to take convexity adjustments into account in the bootstrap on the SOFR curve. I am using cash for the upfront, SOFR swaps from 2Y to the end. In the mid term I use 2 1M SOFR futures and 7 3M SOFR futures. For each of the 9 futures I want to calibrate a simple model (Ho-Lee or maybe Vasicek) to on ...
I have been researching volatility smoothing techniques and risk-neutral pdf. I noticed one interesting post in https://quant.stackexchange.com/questions/73579/does-the-risk-neutral-pdf-that-is-derived-using-litzenberger-breeden-method-corr Kevin, the answerer of the post, pointed out a property to derive spot de...
Can the risk neutral pdf derived from Breeden-Litzenberger Method be used to calculate vega and theta?
No, vega cannot be derived in a model-free manner. The reason for this is because in contrast to delta and gamma, there are multiple definitions of vega, and an even deeper underlying reason may be that spot volatility is not an observable. The consequence of this is that 'vega' starts to depend on the quoting mechanis...
No, **vega** cannot be derived in a model-free manner. The reason for this is because in contrast to delta and gamma, there are multiple definitions of vega, and an even deeper underlying reason may be that spot volatility is not an observable. The consequence of this is that 'vega' starts to depend on the quoting mech...
I am trying to take convexity adjustments into account in the bootstrap on the SOFR curve. I am using cash for the upfront, SOFR swaps from 2Y to the end. In the mid term I use 2 1M SOFR futures and 7 3M SOFR futures. For each of the 9 futures I want to calibrate a simple model (Ho-Lee or maybe Vasicek) to on ...
This has been posted a few times now, so I will invest the time on a full response. ### FRA / Futures convexity has **nothing** to do with profits/losses being **immediately** recognised on the future through margin settlement, and potential reinvestment, whilst deferred on the FRA. Although the opposite seems to...
This has been posted a few times now, so I will invest the time on a full response. ### FRA / Futures convexity has **nothing** to do with profits/losses being **immediately** recognised on the future through margin settlement, and potential reinvestment, whilst deferred on the FRA. Although the opposite seems to...
This has been posted a few times now, so I will invest the time on a full response. ### FRA / Futures convexity has **nothing** to do with profits/losses being **immediately** recognised on the future through margin settlement, and potential reinvestment, whilst deferred on the FRA. Although the opposite seems to...