ACG | R Documentation |
Density and simulation of the Angular Central Gaussian (ACG)
distribution on
S^{p-1}:=\{\mathbf{x}\in R^p:||\mathbf{x}||=1\}
, p\ge 1
. The density at
\mathbf{x} \in S^{p-1}
, p\ge 2
, is given by
c^{\mathrm{ACG}}_{p,\boldsymbol{\Lambda}}
(\mathbf{x}' \boldsymbol{\Lambda}^{-1} \mathbf{x})^{-p/2}
\quad\mathrm{with}\quad c^{\mathrm{ACG}}_{p,\boldsymbol{\Lambda}}:=
1 / (\omega_p |\boldsymbol{\Lambda}|^{1/2})
where \boldsymbol{\Lambda}
is the shape matrix, a
p\times p
symmetric and positive definite matrix, and
\omega_p
is the surface area of S^{p-1}
.
d_ACG(x, Lambda, log = FALSE)
c_ACG(p, Lambda, log = FALSE)
r_ACG(n, Lambda)
x |
locations in |
Lambda |
the shape matrix |
log |
flag to indicate if the logarithm of the density (or the normalizing constant) is to be computed. |
p |
dimension of the ambient space |
n |
sample size, a positive integer. |
Due to the projection of the ACG, the shape matrix
\boldsymbol{\Lambda}
is only identified up to a constant,
that is, \boldsymbol{\Lambda}
and
c\boldsymbol{\Lambda}
give the same ACG distribution.
Usually, \boldsymbol{\Lambda}
is normalized to have trace
equal to p
.
c_ACG
is vectorized on p
. If p = 1
, then the ACG is the
uniform distribution in the set \{-1, 1\}
.
Depending on the function:
d_ACG
: a vector of length nx
or 1
with the
evaluated density at x
.
r_ACG
: a matrix of size c(n, p)
with the random sample.
c_ACG
: the normalizing constant.
Eduardo García-Portugués, Davy Paindaveine, and Thomas Verdebout.
Tyler, D. E. (1987). Statistical analysis for the angular central Gaussian distribution on the sphere. Biometrika, 74(3):579–589. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1093/biomet/74.3.579")}
tangent-elliptical
.
# Simulation and density evaluation for p = 2
Lambda <- diag(c(5, 1))
n <- 1e3
x <- r_ACG(n = n, Lambda = Lambda)
col <- viridisLite::viridis(n)
r <- runif(n, 0.95, 1.05) # Radius perturbation to improve visualization
plot(r * x, pch = 16, col = col[rank(d_ACG(x = x, Lambda = Lambda))])
# Simulation and density evaluation for p = 3
Lambda <- rbind(c(5, 1, 0.5),
c(1, 2, 1),
c(0.5, 1, 1))
x <- r_ACG(n = n, Lambda = Lambda)
if (requireNamespace("rgl")) {
rgl::plot3d(x, col = col[rank(d_ACG(x = x, Lambda = Lambda))], size = 5)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.