The A^2 statistic is Anderson and Darling (1952), read from the corpus
PDF as Hedderich, Sachs and Reynarowych eq (7.33); the single
implementation lives in Adcore and is called, not
copied. The probability-integral transform is the generalized
extreme value distribution function, Coles (2001), An Introduction to
Statistical Modeling of Extreme Values, eq (3.2):
G(z) = exp(-(1 + xi (z-mu)/sigma)^(-1/xi)) on
1 + xi (z-mu)/sigma > 0, and
G(z) = exp(-exp(-(z-mu)/sigma)) when xi = 0.
Details
Parameters are supplied by the caller, not fitted. That is deliberate: the package GEV/GPD fitters are Nelder-Mead and agree across language arms only to about 1e-4, which would make the statistic irreproducible. No p-value is returned: Stephens (1986) critical values depend on which parameters were estimated and how, and that chapter was not obtainable here.
Examples
Adgev(c(0.1, 0.9, 1.4, 2.2, 3.1), 1, 1, 0.1)$statistic
#> [1] 0.1581766
