instruction
stringlengths
15
26.1k
I was reading the paper Statistical Arbitrage in the US Equity Market and I couldn't understand the figure that plots the histogram of the empirical distribution of characteristic time to mean reversion. Specifically, the x axis is the estimated mean reversion days, what does the y axis represent? Is it 1/speed of mean...
I'm calculating Fama-French portfolio returns for a country, to test the sign and significance of alphas for portfolios sorted by my variable of interest. I can't use Fama-French data library factors as these are not specific enough to my country. My question is that, if i'm assessing returns and alphas for 10 diffe...
I have a portfolio of assets. Each assets have been discretionally (based on investment manager experience) related to economic factors like (like exchange rate inflation spread etc). Now for each asset I want to see if effectively those fator are relevant in order to make a regression and find the betas (coefficient ...
I think your question can be split into two parts: (i) how to value a swap mathematically and (ii) how swaps actually work as a traded product. **Part (i)**: As noob2 pointed out, "theoretically", a swap is valued with the help of two curves: one "forward" curve and one "discounting" curve. Say you want to "value...
Interactive Broker API error 321?
I have done a asympotical principle component analysis (APCA) ,using `eigen()` in R, of a global dataset of excess returns. I took the resulting eigenvectors (E) of the top principle components as a set and compared them with another set containing 5 asset pricing factors (F) using the function `cancor(F,E)`, ending i...
Hi All: I've started reading "volatility trading" by Euan Sinclair and it's a very nice book. It's not so theoretical but instead focuses on the practicalities when dealing with trading options. I've never worked in options ( so just understand the basics from textbooks such as cox and rubinstein, baxter rennie etc ) a...
**traditional credit rating** uses a set of macro and micro factors (country of incorporation political stability, economy, etc. ) and assigns subratings via a set a scorecards, based on the company's specifics, the final rating being an analyst consensus and essentially an aggregation of the subratings. this is updat...
Does this have any relation to it's symmetric normal distribution?
What is the meaning that Geometric Brownian motion is leptokurtic?
I want to **focus on companies**-performance only and as much as possible **remove the effect of macro-economy**. Interest rate changes, crisis, inflation etc. There are 2 goals: 1) **Simplification** of analysis for **value investing**. When I look at company financial report numbers and historical time series ...
How to normalise companies relative to each other? Remove the effect of macro-economy?
I think your question can be split into two parts: (i) how to value a swap mathematically and (ii) how swaps actually work as a traded product. **Part (i)**: As noob2 pointed out, "theoretically", a swap is valued with the help of two curves: one "forward" curve and one "discounting" curve. Say you want to "value...
I have to show monotonicity for a more general case than the expected shortfall. I have to show that $E(X|X \geq a) \geq E(X|X \geq b), \forall a,b \in \mathbb{R}$ so that $a\geq b$ and $F_X(a-)<1$. This is how I started: $E(X|X\geq b)=\frac{\int_b^{\infty}X dP}{P(X\geq b)}=\frac{\int_b^{a}X dP+\int_a^{\inft...
Does this have any relation to the symmetry of the normal distribution?
My firm generates electricity from wind. Accordingly, most of my generation takes place at night, when prices are low -- and, due to congestion / oversupply, often sharply negative -- so much so that the spread between daytime and nighttime (or, more generally, "peak" and "off-peak") prices itself is often negative. ...
Should I hedge this spread with a spread option or an insurance product?
I have done a asympotical principle component analysis (APCA), using `eigen()` in R, of the covariance matrix of a global dataset of excess returns. I took the resulting eigenvectors (E) of the top principle components as a set and compared them with another set containing 5 asset pricing factors (F) using the functio...
I have done a asympotical principle component analysis (APCA), using `eigen()` in R, of the covariance matrix of a global dataset of excess returns. I took the resulting eigenvectors (E) of the top principle components as a set and compared them with another set containing 5 asset pricing factors (F) using the functio...
I provide a solution in three steps. - The first step carefully outlines how to split up the expectation and what new measures are used. This first step does not require any special model assumption and holds in a very general framework. I derive a formula for the option price that resembles the standard Black-Scho...
I provide a solution in three steps. - The first step carefully outlines how to split up the expectation and what new measures are used. This first step does not require any special model assumption and holds in a very general framework. I derive a formula for the option price that resembles the standard Black-Scho...
Forex trailing stops - better alternatives?
I provide a solution in three steps. - The first step carefully outlines how to split up the expectation and what new measures are used. This first step does not require any special model assumption and holds in a very general framework. I derive a formula for the option price that resembles the standard Black-Scho...
I provide a solution in three steps. - The first step carefully outlines how to split up the expectation and what new measures are used. This first step does not require any special model assumption and holds in a very general framework. I derive a formula for the option price that resembles the standard Black-Scho...
I provide a solution in three steps. - The first step carefully outlines how to split up the expectation and what new measures are used. This first step does not require any special model assumption and holds in a very general framework. I derive a formula for the option price that resembles the standard Black-Scho...
I have done a asympotical principle component analysis (APCA), using `eigen()` in R, of the covariance matrix of a global dataset of excess returns. I took the resulting eigenvectors (E) of the top principle components as a set and compared them with another set containing 5 asset pricing factors (F) using the functio...
As @ir7 did, I only briefly want to add to @noob2's spot-on answer. He's of course right and $\Lambda=\Delta\frac{S}{V}$ decides how risky the option is compared to the stock. Firstly, note that $\Lambda=\frac{\frac{\partial V}{V}}{\frac{\partial S}{S}}=\frac{\partial V}{\partial S}\frac{S}{V}$. An economist would c...
This question is sort of a continuation of [this][1], but i wanted to share the progress i made and ask for help on the part where i'm stuck. The short story is that i have a pattern stored in a simple array of data, then i have a dataset and i need to check for occurrences of the pattern i specified on the other da...
As @ir7 did, I only briefly want to add to @noob2's spot-on answer. He's of course right and $\Lambda=\Delta\frac{S}{V}$ decides how risky the option is compared to the stock. Firstly, note that $\Lambda=\frac{\frac{\partial V}{V}}{\frac{\partial S}{S}}=\frac{\partial V}{\partial S}\frac{S}{V}$. An economist would c...
your problem is **pattern recognition**. considering you already identified the desired output pattern (entry/exit points), you can use [supervised][1] methods of machine learning to train. many are available, a support vector machine for instance, recommend you to check the [scikit learn][2] module out, it has practi...
your problem is **pattern recognition**. considering you already identified the desired output pattern (entry/exit points), you can use [supervised][1] methods of machine learning to train. many are available, a support vector machine for instance, recommend you to check the [scikit learn][2] module out, it has practi...
I understand that retail brokers pass their customers' trades on to trading firms, and receive a payment for order flow in return. These trading firms carry out the trades and presumably also have to pay per-trade exchange fees to the stock exchanges. So if they pay to both sides, how can they make money? A recent ...
How do trading firms that pay for order flow make money from "arbitrage"?
How much can I reasonably make if I buy a long straddle just as soon as earnings release day is announced and ride the rise in implied volatility along with any movements till the earnings release date just before earnings is released? If I do this without waiting for the gap up or down from the release, will I make...
Is this a new way to profit from earnings releases using long straddles?
"The models implemented are: Nelson-Siegel, Diebold-Li and Svensson" is written in the description of the packages "YieldCurve". However, I can't find a specific estimation function for the diebold-li parameters. How can I fix this problem with this packages or do you know other packages for the estimation?
Is there a packages to estimate Diebold-Li Parameters in R?
Are there noticeable jumps in index options price due to systematic hedging of structured products close to big expiry dates?
I am having a bit of trouble understanding how to obtain the option implied distributions. I have strike levels, deltas and implied vols for a call option that expires in 6 months. Roughly 40 data points for each of the three parameters. I would like to interpolate this data to a cubic spline, obtain a p.d.f. a...
**Regular returns** (log-differenced prices) have statistical distributions that are bell-shaped and **unimodal** (one mode/peak) despite being non-normal and fat-tailed. **Cumulative returns**, on the other hand, computed from regular returns as $[\prod (1+r)] -1$, are **bi-modal** (with two modes/peaks). Is there ...
Why do cumulative returns have a bimodal distribution?
I feel very confused about the greeks analysis for the broken wing butterfly strategy. Let's say for the stock ABC, we enter into a such strategy: we long a put option with strike $k_1$ and another put option with strike $k_3$,and at the same time short two put options with strike $k_2$, where $k_2-k_1>k_3-k_2$. ...
How to understand broken wing butterfly option strategies?
Are there any techniques that can make a multivariate random number generating process for stock prices/returns, like geometric Brownian motion via Cholesky, also simulate a finite number of market regimes (say 2 or 3) so that systematic (market-induced) movement in prices are experienced for the same span of time inte...
How to simulate asset prices/returns that display market regimes?
>Suppose two assets in the Black Scholes world have the same volatility, but different drifts and that one has downward jumps at random times. How does this affect the option prices? I would have thought that downward jumps would decrease the value of the call option because you have more chance of being out of the ...
We have a data set up that provides us a list of holidays and weekends which is different from the country or currency calendars.Is there any method exposed in Quantlib calendars which expects a list of holday dates and weekends to form a calendar?
Why the clean price is mostly quoted in the US bond markets and the dirty price is mostly quoted in the European bond markets?
Something like this? myCalendar = ql.WeekendsOnly() dates = ['19-06-2019', '07-05-2020'] for date in dates: myCalendar.addHoliday( ql.Date(date, '%d-%m-%Y') ) Or if for some reason the weekends are different, start from `ql.NullCalendar()`
Consider a Black Scholes market with constant coefficients, a bond and two risky assets: $$dB_{t}=r B_{t}dt \\ dS_{t}^{i}=S_{t}^{i}(b_{i}dt+\sigma_{i,1}dW_{t}^{1}+\sigma_{i,2}dW_{t}^{2})$$ where $i=1,2$ and $W_{t}^{1},W_{t}^{2}$ are two independent Brownian Motions. I want to determine the fair price of the optio...
Are there any techniques that can make a multivariate random number generating process for stock prices/returns, like **geometric Brownian motion via Cholesky**, also include the simulation of a finite number of market regimes (say 2 or 3) so that systematic (market-induced) movement in prices are experienced across al...
as I read-throughs the definition of SP500, there is no clear explanation of the Divisor. I wonder what is it and where can I read more about it?
How are the divisor of SP500 determined?
I read through the definition of S&P 500, there is no clear explanation of the Divisor. I wonder what is it and where can I read more about it?
For example i would like to price \begin{equation*} E^{Q} \left[ e^{-\int_{0}^{T}r_{s}^{cur}ds} f \left( S_{T_f}^{cur_1} \right) | \mathcal{F}_{0} \right] = B_{cur}(0,T)E^{Q^{cur}_{T}}[ f(S_{T_f}^{cur_1})|\mathcal{F}_{0}] \end{equation*} I have at my disposition the risk neutral currency implied density for $S_...
How is the implied risk neutral density affected when changing numeraire?
multivariate MC: what am I doing wrong?
Multivariate MC: what am I doing wrong?
I want to calculate the `NPV` of a Variance Swap wherein the cash flow happens every months based on the standard Variance formula of the close prices of S&P500 for prior 30 business days. We may assume the strike as `K`. Is there any standard formula for pricing this? As far as I know, the standard formula for Vari...
I want to calculate the `NPV` of a Variance Swap wherein the cash flow happens every months based on the standard Variance formula of the close prices of S&P500 for prior 30 business days. We may assume the strike as `K`. Is there any standard formula for pricing this? As far as I know, the standard formula for Vari...
The $k$ period log return is defined as $$r_{t}(k)=log(S_{t}/S_{t-k}),$$ Where $S_{t}$ is the stock closing price at time $t$. For argument sake, assume that by time I mean a stock trading day and historical stock closing prices are known and denoted by $S_{1}, S_{2}, S_{3}, ...., S_{T-1}$. Here are my questions: 1...
since vega is defined as option value changes regarding the implied vol parallel shift, how is vega defined or calculated in stochastic vol models since implied vol is not an input there? thank you.
how to calculate vega in stochastic vol?
I understand that Garch models are useful to predict volatility. But are they useful for hedging in practice? If I want to hedge volatility, why shouldn't I just use a Variance Swap? In other words, other than forecasting volatility, what is the use of Garch type models?
Garch models - are they useful for hedging? If so how?
How to fix my Ornstein-Uhlenbeck parameter MLE in Python?
@Matt Wolf has some good information. In regards to your comment of 'trading against other clients'; to avoid this you will want to participate in a "true ECN". Believe it or not, that might require expensive setup (minimum flow requirements, minimum order sizes, etc) especially if the flow is anonymous. [HotspotFx...
Diebold/Li is not a separate yield-curve model: for a given cross-section of yields, they fix the shape parameter in Nelson-Siegel and then estimate the remaining parameters via linear regression. See [Calibrating the Nelson-Siegel-Svensson Model][1]. The function `NSf` in package in package [`NMOF`][2], which I main...
In the context of EU action on sustainable finance, the European Commission has initiated a series of regulations in order to achieve the goals of Paris Agreement on sustainability. One of those regulations is the disclosure regulation, it compels investment managers to reveal more information regarding the sustainab...
Sorry if my question is a bit basic. I am considering the default model as used eg in Vasicek (I think this goes back at least to Merton, though) that looks at an unobserved quantity modeling the assets of a counterparty through a logarithmic Wiener process $$dA_t = \mu A_tdt + \sigma A_tdB_t$$ with solution $$A_t =...
We have a simple BS-market of one risky asset $S_{t}$, a bond $B_{t}$ and a digital option $X$ on the risky asset with value process $V(t,S_{t})$. I was able to derive $V(t,S_{t})$ using risk-neutral valuation. Now, I am supposed to set up a replicating strategy for this option, i.e. find a self-financing trading stra...
Why do replicating strategies delta hedge?
Sorry if my question is a bit basic. I am considering the default model as used eg in Vasicek (I think this goes back at least to Merton, though) that looks at an unobserved quantity modeling the assets of a counterparty through a logarithmic Wiener process $$dA_t = \mu A_tdt + \sigma A_tdB_t$$ with solution $$A_t =...
Sorry if my question is a bit basic. I am considering the default model as used eg in Vasicek (I think this goes back at least to Merton, though) that looks at an unobserved quantity modeling the assets of a counterparty through a logarithmic Wiener process $$dA_t = \mu A_tdt + \sigma A_tdB_t$$ with solution $$A_t =...
Following the logic of [Ben-Meir and Schiff (2012)](https://arxiv.org/pdf/1204.3452.pdf) and this [question](https://quant.stackexchange.com/questions/30138/variance-of-a-straddle-black-scholes) the first, second, third and fourth raw moments of a put are: [![enter image description here][1]][1] Similarity, for a...
I've been assigned with the task of modelling zero rate curve. I did it with two models: Vasicek and CIR. Looking at the two curves produced, I can see that one is closer to the observed curve than the other, but I am asked to perform some quantitative tests to confirm this observation. My question is this: Do you kno...
Choosing which interest rate model to go with?
If you are buying VOD LN you are buying a cash equity (did you mean as a single stock future?), therefore you can hold this securtity in any custodian, or just as a certifcate under your bed. Futures are cleared by many different firms as long as they are members of the exchange of which the future is offerred on. ...
I'm developing a deep reinforcement learning based approach to market-making. In order to implement this, I need to define the appropriate actions and define environmental steps. While doing some literature research, I've encountered various market-making formulations. For example, [Avellaneda and Stoikov][1] seem t...
I'm developing a deep reinforcement learning based approach to market-making. In order to implement this, I need to define the appropriate actions and define environmental steps. While doing some literature research, I've encountered various market-making formulations. For example, [Avellaneda and Stoikov][1] seem t...
The expected return of a portfolio can be formulated as a weighted average of the constituent assets' returns: $$r_p = w_1 r_1 + w_1 r_1 + \dots + w_N r_N + \epsilon$$ Does it also follow that the empirical distribution, or density, of a portfolio's return series (a vector with observations $r_{p,t=1}, r_{p,t=2},...
Density of a portfolio's returns is the weighted average of asset distributions?
The expected return of a portfolio can be formulated as a weighted average of the constituent assets' returns: $$r_p = w_1 r_1 + w_2 r_2 + \dots + w_N r_N + \epsilon$$ Does it also follow that the empirical distribution, or density, of a portfolio's return series (a vector with observations $x_{t=1}, x_{t=2},$ et...
I'm still trying to wrap my head around the fact that in 2017, the price to books for European banks [fluctuated](https://www.spglobal.com/marketintelligence/en/news-insights/podcasts/street-talk-episode-64) wildly ranging from well above 2 to well below 0.5. Of course, a British bank doing well would trade way high...
How is it that price to book of a bank can fluctuate so wildly?
You mean aside from the fact that stock price can fluctuate wildly? There's no 'why', per se, and, as I imagine you're coming to find out, P/B (nor P/E, P/S, P/CF or any valuation metric) isn't a panacea for identifying undervalued companies. It's a proxy of sorts. 1 is obviously a kind of floor, but imperfe...
You mean aside from the fact that stock price can fluctuate wildly? There's no 'why', per se. P/B (nor P/E, P/S, P/CF or any valuation metric) isn't a panacea for identifying undervalued companies. It's a proxy of sorts. 1 is obviously a kind of floor, but imperfect (where break-up value = current market pr...
I have a dataset of monthly data. One column is my target variable and all the other are my feature. I have computed correlation between my target and all the other feature and then I made linear regression and got my betas and R2. Now my question is more theoretical. if I oversample to daily data (I used a linear ...
does oversampling affect the correlation?
I would like to approximate bond yields in python. But the question arose which curve describes this better? ------------------------------------------------------------------------ ``` import numpy as np import matplotlib.pyplot as plt x = [0.02, 0.22, 0.29, 0.38, 0.52, 0.55, 0.67, 0.68, 0.74, 0.83, 1.05, 1.06,...
# What makes a particular fit good? Naturally for quantitative finance (and really for any quantitative science), while we can sometimes assess the performance of something by eye, this is not a reliable metric. Typically assessing something by eye is only acceptable when throwing away bad/awful fits. You should not...
The "price" of something is a historical value, i.e. it's the price at which the last trade happened, *in the past*. The information in the order book, together with the size and direction of incoming orders are what will determine the prices of the next trades. That's what you're really interested in. Here's a toy...
When we value the floating leg of a standard vanilla swap, we replace the expectation of the future floating rates by the forward rates known today. However my understanding is that the forward rate is equal to the expectation of a spot rate only under the corresponding maturity forward measure. So for example if we h...
Which measure is used to price a swap?
When we value the floating leg of a standard vanilla swap, we replace the expectation of the future floating rates by the forward rates known today. However my understanding is that the forward rate is equal to the expectation of a spot rate only under the corresponding maturity forward measure. So for example if we h...
If we have an order book and we assume that we know there is only one market maker, how can we determine exactly the spread of the market maker? What if there are more than one market makers?
My data consist of monthly electricity futures contracts. Unlike other commodities, electricity is delivered throughout a month (rather than on a specific date), which means that, as the active month elapses, the price of the electricity contract converges to the monthly average. Unfortunately, however, volatility is n...
In his paper, Eugene Fama gives the definition of a "fair game" as given below. I disagree. AFAIK, a martingale has the following property: $E[X_{t+\tau} | X_t] = X_t$. What am I missing? [![enter image description here][1]][1] [1]: https://i.stack.imgur.com/AkrgJ.png
Fama: Efficient Capital Markets: A Review of Theory and Empirical Work - are martingales incorrect?
In his paper, Eugene Fama gives the definition of a "fair game" as given below. I disagree. AFAIK, a martingale has the following property: $E[X_{t+\tau} | X_t] = X_t$. What am I missing? [![enter image description here][1]][1] Footnote 9 says: [![enter image description here][2]][2] And again, in a previou...