I would like to compute tail probabilities of the standardized multivariate normal distribution for different dimensions. For example, in the case of bivariate normal I need to compute the gray area on the figure pasted below (In this particular case, the area is defined by $\mathbf{x} > 2$.)
I found somewhere (but unfortunately, I lost the reference) that the probability that the data point $\mathbf{x}$ is outside the spherical contour with radius $\alpha$ should be calculated as:
$$ \begin{split} \Pr \left(\frac{f(\mathbf{x})}{f(\mathbf{0})} \geq \alpha\right) &= P(\mathbf{x}^{T} \mathbf{x} \leq -2 \ln (\alpha)) \\ &= \int_{0}^{-2 \ln(\alpha)} f_{\chi_{d}^{2}(\mathbf{x}^{T} \mathbf{x})} \\ &= F_{\chi_{d}^{2}} (-2 \ln (\alpha)) \end{split} $$ where $F$ is cumulative distribution function.
I find myself lost in this equation. I kindly ask for computational example how to compute desired probability (in whatever programming language).
SOLUTION
I found the solution myself:
pchisq(q = alpha^2, df = d)
alpha
stands for radius and d
stands for dimension.
mvtnorm
package inR
can do this. Check this document for many examples. I think you want thepmvnorm
function. $\endgroup$mvtnorm
function, but I would also like to understand how to compute it manually. $\endgroup$