Hot answers tagged

9

Upon close reading, this appears to be 3 (interesting) questions, not one. I'm not sure if the mods have the tools needed to split it up, so I'm just going to write down the three questions as I see them and then deal with them one by one. Note, it is simpler for me to talk about variance instead of volatility. This has no material impact on the answer. ...


6

Well there are two main things to consider here. Many implementation of Black-Litterman use the market portfolio and the ex post volatility and correlation structure to back out implied returns to use as prior. As far as I know, there is no standard way to reverse-engineer the optimization problem in the presence of nonnormal markets. (the first guess is ...


5

The VaR of level $\alpha$ a loss random variable (the bigger the worse) is the quantity $q$ such that the loss is bigger with probability $1-\alpha$. Thus we need a $q$ such that $$ P[L>q] = 1-\alpha, $$ where we can imagine $\alpha=99\%$ and thus we need the starting point of the $1\%$ tail. Because we have a probability of a loss of size $0$ of $75\%...


4

The rsgt is a skewed generalized t distribution, whereas your picture is a skewed student-t distribution. Try using fGarch package. Plot reproduced: library(fGarch) x<-seq(-2.5, +2.5, by=0.001) plot(x, fGarch::dsstd(x, mean = 0, sd = 1, nu = 30, xi = 1 + 0.5), type = "l", ylim=c(0, 2.4), lty = 1, xlab="z", ylab=expression(paste("...


3

You know that : $X \sim N(\mu,\sigma^2)$. $Z = \large\frac{X-\mu}{\sigma}$. $\text{Var}(Z) = \large\frac{1}{\sigma^2}\text{Var}(X) = \large\frac{1}{\sigma^2}\sigma^2 = 1$. So that $Z \sim N(0,1)$. However note that the pdf evaluated for X and Z have different domains. The following figure illustrate it : $X$ is plotted in a) and $Z$ in b) ...


3

When possible, I look at implementations in IMSL and the GSL for really good accuracy. Neither one appears to implement the Wald (inverse gaussian) or its quantile function. Matlab does have the distribution (as inversegaussian) so you could roll your own with fzero() or another root-finder based on that if you are unhappy with the accuracy, or for testing ...


2

Normal distribution makes most sense these days for ratesthat are very low, or even negative, like euribor, chf libor Normal distribution is what is assumed by option brokers impliedvolatility quotes for these currencies


2

You might also look at the boost package which should (I'm no expert for this) be usable within C#. It comes with an implementation of the inverse normal distribution which is explained in the online documentation http://www.boost.org/doc/libs/master/libs/math/doc/html/math_toolkit/dist_ref/dists/inverse_gaussian_dist.html Here they claim quite a high ...


2

Assuming you've used this definition for the NIG distribution and that you've managed to come up with estimates $(\hat{\alpha}, \hat{\beta}, \hat{\mu}, \hat{\delta} )$ of the individual NIG parameters, your question boils down to: "How to simulate paths from the global log-return process $R_t = \ln(S_t/S_0)$ for all $t \in [0,T]$, assuming i.i.d. $NIG(\...


1

You will need a 'pseudo' random number generator - most stats programming languages have them (Matlab, R, Python...). But GBM is defined with Normal increments $N(0,\sigma^{2}(T-t))$ so I dont think using Student's t distribution is a good idea, never seen it in any literature/applications. It is however used for instance in GARCH modelling.... Random ...


1

$$\begin{split}\sum_{k=0}^{[nx]}\binom{n}{k}s^k(1-s)^{n-k}& =\sum_{k=0}^n \mathbb{1}_{k\leq [nx]} \binom{n}{k}s^k(1-s)^{n-k} \\ & = \sum_{k=0}^n \mathbb{1}_{k\leq nx} \binom{n}{k}s^k(1-s)^{n-k} \\ & = \mathbb{P}(\mathcal{B}(n,s)\leq nx)\\ & = \mathbb{P}\left(\frac{\mathcal{B}(n,x)}{n}\leq x\right)\end{split}$$ where $\mathcal{B}(n,s)$ is a ...


1

The answer is undefined as the probability distribution provided is invalid, the probabilities don't sum up to one, so there's not much to expand on here.


1

In general, an option payoff cannot be normal, as the payoff is generally positive, while a normal variable can be negative. For a standard call option, the distribution function can be computed from the distribution of the underlying stock. Specifically, consider the vanilla European option payoff $X=(S_T-K)^+$. Then, for $x < 0$, \begin{align*} P(X \le ...


1

VaR for GED in R package(fGarch) qged(p, mean = 0, sd = 1, nu = 2) #Example qged(.01, mean=1000, sd=2000) [1] -3652.696 where, $1-p$ is confidence level.


1

Have a look at ?dnorm, and rather use the standardized value as argument in your function, in addition to mean and sd: a_<-dnorm((0.001-0.0001)/0.4, mean=0, sd=1) Hope it helps [EDIT] Likewise from ?dsgt st<-(0.001-0.0001)/0.4 skewt<-dsgt(st, mu=0, sigma=1, lambda=0.1, p = 2, q=5, mean.cent=TRUE, var.adj=TRUE) results in skewt=0.4302996 (close ...


1

1- It seems to me there is a problem in the original code the variable b should be defined as b= sqrt(1 + 3*lamda^2 - a^2) 2- The likelihood is defined just after equation 8. in the paper. You have to take into account the $ \frac{1}{\sigma}$ term (in $ \frac{1}{\sigma} \times g(..) $ , ie to scale the densitie) . So the - 0.5*log(h(t)) refers to this ...


1

As an additional (simple) solution I would use the probability integral transform (PIT) of the returns with respect to the generalized pareto distribution. Under the null hypothesis that the distribution is correctly specified, outcomes of the PIT should be independent uniform U[0; 1] random variables. Then you can use traditional independence tests.



Only top voted, non community-wiki answers of a minimum length are eligible