Description Usage Arguments Value Author(s) References Examples
Estimates the p-value of a data set y for a test statistic x0 with the Pareto's distribution function.
1 | PGPD.1(x0,zexc,Nperm,seuil,estim)
|
x0 |
Test statistic of the data set - real number |
zexc |
Data set which results from the initial one y - sorted list of real numbers |
Nperm |
Number of permutations - integer |
seuil |
Threshold used to create the data set zexc composed of the values of y higher or equal to (x0 - seuil) - real number |
estim |
Method to estimate the parameters of Pareto's function - String: either "EMV" for the method of maximum likelihood or "PWM" for the method of probability weighted moments |
Returns a list composed of:
p |
The value of the estimated p-value. - real number |
k |
The estimated parameter k of Pareto's cumulative distribution function if it was used to compute the p-value - real number |
a |
The estimated parameter a of Pareto's cumulative distribution function if it was used to compute the p-value - real number |
Marion
Theo A. Knijnenburg, Lodewyk F. A. Wessels, Marcel J. T. Reinders and Ilya Shmulevich, Fewer permutations, more accurate P-values, Bioinformatics.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | PGPD.1(3,tail(sort(rnorm(1e6)),500),1e6,2,"PWM")
## The function is currently defined as
function (x0,zexc,Nperm,seuil,estim)
{
M<-nb_exc(x0-seuil,zexc)
if(M >= 10)
return(list( p = M/Nperm,
k = NA,
a = NA ))
else {
result<-FGPD(x0-seuil,zexc,estim)
return(list( p = length(zexc)/Nperm*(1-result$val),
k = result$k,
a = result$a ))
}
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.