dot-gpdFittedPValue: Compute p-value based on generalized Pareto distribution...

.gpdFittedPValueR Documentation

Compute p-value based on generalized Pareto distribution fitting


Computes a p-value based on a generalized Pareto distribution (GPD) fitting. This procedure may be used in the semi-parametric 2-Wasserstein distance-based test to estimate small p-values accurately, instead of obtaining the p-value from a permutation test.


.gpdFittedPValue(val, distr.ordered)



value of a specific test statistic, based on original group labels


vector of values, in decreasing order, of the test statistic obtained by repeatedly permuting the original group labels


A vector of three, see Schefzik et al. (2020) for details:

  • pvalue.gpd: p-value obtained when using the GPD fitting test

  • ad.pval: p-value of the Anderson-Darling test to check whether the GPD actually fits the data well

  • N.exc: number of exceedances (starting with 250 and iteratively decreased by 10 if necessary) that are required to obtain a good GPD fit, i.e. p-value of Anderson-Darling test \geq 0.05


Schefzik, R., Flesch, J., and Goncalves, A. (2020). waddR: Using the 2-Wasserstein distance to identify differences between distributions in two-sample testing, with application to single-cell RNA-sequencing data.

goncalves-lab/waddR documentation built on June 29, 2023, 12:18 a.m.