The hardware and bandwidth for this mirror is donated by METANET, the Webhosting and Full Service-Cloud Provider.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]metanet.ch.
This vignette uses a synthetic series. It shows the scalar case of affine-equivariant adjusted-range self-normalization, where the construction reduces exactly to adjusted-range self-normalization: the scaled estimation error is divided by the adjusted range (maximum minus minimum) of the centered partial-sum path.
The series is a stationary first-order autoregression with mean 0.3 and autoregressive coefficient 0.5. The parameter of interest is the mean.
library(aersn)
set.seed(2026)
n <- 300
y <- 0.3 + as.numeric(arima.sim(list(ar = 0.5), n))
fit <- aersn_mean(y)
fit
#> Affine-equivariant adjusted-range self-normalization (increment hull)
#> model: sample mean (psi_t = Y_t - Ybar)
#> n = 300 observations; q = 1 parameter
#> centering: calendar time, tau(r) = r
#> estimate:
#> theta
#> 0.4159
#> hull diagnostics: numerical rank 1 of 1 ; condition 1.000 ; min projected range 2.083 ; spread 1.000
#> Use aersn_test(), confint(), aersn_contrast(), aersn_region(), plot().The influence contribution of observation t for the sample mean is \(Y_t - \bar Y_n\). The centered path \(\hat G_n(k/n) = n^{-1/2}\sum_{t \le k}(Y_t - \bar Y_n)\) starts and ends at zero:
For \(H_0: \theta_0 = 0\) the statistic is \(T_n(0) = |\sqrt n(\bar Y_n - 0)| / \{\max_k \hat G_n(k/n) - \min_k \hat G_n(k/n)\}\). Its limit is \(|M| = |Z| / R\), where \(Z\) is standard normal and \(R\) is the range of an independent standard Brownian bridge. Two reference laws are available:
reference = "continuous"), whose five-percent critical
value is 1.7058; andn intervals as the sample path. Matched-grid
quantiles are larger because a path observed on a grid has a smaller
range than the continuous path. The manuscript uses matched-grid
quantiles as critical values.aersn_test(fit, null = 0, reference = "continuous")
#>
#> Adjusted-range increment hull test, q = 1
#>
#> data: fit
#> T = 3.459, q = 1, n = 300
#> alternative hypothesis: true parameter is not equal to the null value
#> null value: theta = 0
#> estimate: theta = 0.4159
#> critical value at level 0.95: 1.706 (reject)
#> p-value = 0.0005637 (closed-form law)
#> reference: closed-form continuous-path law of |M| (q = 1)
aersn_test(fit, null = 0, draws = 20000, seed = 1)
#>
#> Adjusted-range increment hull test, q = 1
#>
#> data: fit
#> T = 3.459, q = 1, n = 300
#> alternative hypothesis: true parameter is not equal to the null value
#> null value: theta = 0
#> estimate: theta = 0.4159
#> critical value at level 0.95: 1.837 (reject)
#> p-value = 0.00130 (Monte Carlo s.e. 0.00025, resolution 0.000050)
#> reference: matched-grid Monte Carlo law for increment-hull gauge: q = 1, uniform grid with n = 300 intervals, 20000 draws, seed 1The matched-grid p-value is a Monte Carlo estimate; its standard error and resolution (one over the number of draws) are reported. A one-sided alternative uses the signed ratio:
aersn_test(fit, null = 0, alternative = "greater", reference = "continuous")
#>
#> Adjusted-range increment hull test, q = 1
#>
#> data: fit
#> T = 3.459, q = 1, n = 300
#> alternative hypothesis: true parameter is greater than the null value
#> null value: theta = 0
#> estimate: theta = 0.4159
#> critical value at level 0.95: 1.397 (reject)
#> p-value = 0.0002818 (closed-form law)
#> reference: closed-form continuous-path law of |M| (q = 1)The confidence interval is \(\bar Y_n \pm (c/\sqrt n)\,\mathcal R(\hat G_n)\), where \(c\) is the reference quantile.
confint(fit, level = 0.95, draws = 20000, seed = 1)
#> Simultaneous (joint-region projection) Adjusted-range increment hull confidence intervals, level 0.95
#> lower upper
#> theta 0.195 0.6368
#> critical value 1.837 (reference dimension 1); matched-grid Monte Carlo law for increment-hull gauge: q = 1, uniform grid with n = 300 intervals, 20000 draws, seed 1
confint(fit, level = 0.95, reference = "continuous")
#> Simultaneous (joint-region projection) Adjusted-range increment hull confidence intervals, level 0.95
#> lower upper
#> theta 0.2108 0.621
#> critical value 1.706 (reference dimension 1); closed-form continuous-path law of |M| (q = 1)The interval endpoints are exactly the boundary of the set of null values that the test does not reject:
The test is asymptotically valid when the partial sums of \(Y_t - \theta_0\) satisfy a functional
central limit theorem with positive long-run variance. No bandwidth,
kernel, or block length is chosen. Under strong persistence the
finite-sample null rejection rate exceeds the nominal level; the
manuscript’s simulations report, for example, 14.4 percent at
autoregressive coefficient 0.9 with n = 500 and
q = 2.
These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.