Description Usage Arguments Details Value Note Author(s) References See Also Examples
View source: R/criticalValuesApprox.r
This function computes critical values that can be used to perform the multiscale analysis about a
density with the functions modeHuntingApprox
and modeHuntingBlock
.
1 2 | criticalValuesApprox(n, d0 = 2, m0 = 10, fm = 2, alpha = 0.05,
gam = 2, tail = 10, M = 10 ^ 5, display = 0, path = NA)
|
n |
Number of observations. |
d0 |
Initial parameter for the grid resolution. |
m0 |
Initial parameter for the number of observations in one block. |
fm |
Factor by which m is increased from block to block. |
alpha |
Significance level, real number in (0,1). |
gam |
Weighting exponent for level in each block. |
tail |
Offset, determines together with |
M |
Number of runs to perform. |
display |
If |
path |
If |
For details see the function modeHuntingApprox
and the data set cvModeApprox
.
approx |
A 2-dimensional vector containing the critical value for the test statistic with or without additive correction Γ. |
block |
A vector containing the critical value for each block. |
The asymptotic results in Rufibach and Walther (2010) are only derived for f_m = 2.
Kaspar Rufibach, kaspar.rufibach@gmail.com,
http://www.kasparrufibach.ch
Guenther Walther, gwalther@stanford.edu,
www-stat.stanford.edu/~gwalther
Rufibach, K. and Walther, G. (2010). A general criterion for multiscale inference. J. Comput. Graph. Statist., 19, 175–190.
The resulting critical values are used by the functions modeHuntingApprox
and
modeHuntingBlock
. Critical values
for some combinations of n and α are available in cvModeApprox
and
cvModeBlock
.
1 2 3 4 5 6 7 8 9 10 11 | ## compute critical values and compare to those in cvModeAll and cvModeBlock
## (to see output in R, press CTRL + W)
cv <- criticalValuesApprox(n = 200, d0 = 2, m0 = 10, fm = 2,
alpha = 0.05, gam = 2, tail = 10, M = 10 ^ 2, display = 1, path = NA)
cv1 <- cv$approx; cv2 <- cv$block
data(cvModeApprox); data(cvModeBlock)
cv3 <- cvModeApprox[cvModeApprox$alpha == 0.05 & cvModeApprox$n == 200, 3:4]
cv4 <- cvModeBlock[cvModeBlock$alpha == 0.05 & cvModeBlock$n == 200, 3:6]
rbind(cv1, cv3)
rbind(cv2, cv4)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.