cir_gaps {sphunif} | R Documentation |
Circular gaps
Description
Computation of the circular gaps of an angular sample
\Theta_1,\ldots,\Theta_n
on [0, 2\pi)
, defined as
\Theta_{(2)} - \Theta_{(1)},\ldots,\Theta_{(n)} - \Theta_{(n - 1)},
2\pi - \Theta_{(n)} - \Theta_{(1)},
where
0 \le \Theta_{(1)} \le \Theta_{(2)} \le \ldots \le
\Theta_{(n)} \le 2\pi.
Usage
cir_gaps(Theta, sorted = FALSE)
Arguments
Theta |
a matrix of size |
sorted |
are the columns of |
Value
A matrix of size c(n, M)
containing the n
circular
gaps for each of the M
circular samples.
Warning
Be careful on avoiding the next bad usages of cir_gaps
, which will
produce spurious results:
The entries of
Theta
are not in[0, 2\pi)
.-
Theta
is not sorted increasingly whendata_sorted = TRUE
.
Examples
Theta <- cbind(c(pi, 0, 3 * pi / 2), c(0, 3 * pi / 2, pi), c(5, 3, 1))
cir_gaps(Theta)