Description Usage Arguments Details Value Author(s)
Return the coefficients in the Halton equation for a list of Halton indices (boxes).
1 | halton.coefficients(samp, J, bases = c(2, 3))
|
samp |
A vector of Halton indices. |
J |
A vector of powers of the bases. This determines the level of hierarchy in the Halton boxes and the number of boxes. |
bases |
The bases of the Halton sequence. |
Let digits = halton.coefficients(samp,J,bases),
K = max(J) and
places <- 1/matrix(rep(bases,each=K)^(1:K),K,length(J)).
The coordinate in [0,1) of the lower left corner of
the Halton box with index samp[i] is
colSums(digits[i,,] * places, na.rm = T).
This is how you get the Halton sequence from this routine.
However, if you are interested in the Halton sequence alone,
not the coefficients, call function halton().
An array of size length(samp) X max(J) X length(J)
of coefficients. Row i, column j, page k of this array is the jth coefficient
for the kth dimension of the ith index in samp.
Trent McDonald
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.