value at risk calculation I am to count VaR for a portfolio consisting of $100$ diversified bonds. One bond which is worth $100$ can either give $105$ with $p=0,98$ or $0$ with $p=0,02$. 
This probability can be expressed as $105Y-5$ if I assume $Y$ to be a binary variable ($1$ with $p=0,02$ and $0$ with $p=0,98$). 
How should I proceed to calculate VaR ?
 A: For a given confidence level $\alpha$, the value-at-risk (VaR) is the smallest value $x$ such that the loss $L$ would be exceeded with probability at most $1-\alpha$.
$$VaR_{\alpha} = \inf \{x:P(L>x)\leq(1-\alpha)\} $$
Initially there are $100$ bonds each worth $100$ for a total portfolio value of $V_0=10000.$ If there are $Y$ defaults in one period, the final portfolio value is $105(100-Y).$
Assuming that the bonds are uncorrelated (a strong interpretation of diversified), the number of defaults has a binomial distribution:
$$P(Y=k) = \binom{100}{k}(0.02)^k(0.98)^{100-k}.$$ 
To find VaR, we solve for the smallest integer $j^*$ such that
$$\sum_{k=j^*}^{100}\binom{100}{k}(0.02)^k(0.98)^{100-k} \leq 1-\alpha $$
Also it may be easier to approximate the binomial distribution as a normal distribution with mean $\mu = 100p= 2$ and variance $\sigma^2 = 100p(1-p)= 1.96.$ 
Then we would use the normal distribution function $N(x;\mu,\sigma)$ to find $j^*$ by solving
$$1-N(j^*;\mu,\sigma) = 1-\alpha.$$
At the $95$% confidence level, $1-\alpha = 0.05$ and we find $j^* \approx 5.$  With $5$ defaults, the final portfolio value is $105(100-5)=9975$ and $VaR_{0.95} = 25.$
A: I think there is something fundamentally flawed with this @Pasato @RRL
$\sum_{k=j^*}^{100}\binom{100}{k}(0.02)^k(0.98)^{100-k} \leq 1-\alpha $
If $\alpha$ is .05 or .95 
The minimal integer value of $j*$ for which that sum is valid under the constraints given that $\alpha= .95$ is 6.
The minimal integer value of $j*$ for which that sum is valid under the constraints given that $\alpha= .05$ is 1.
So, either you have not stated the solution clearly enough or there is something buggy happening here.
