View source: R/fishersMethod.R
fishersMethod | R Documentation |
Fisher's method to combine multiple p-values
fishersMethod(p, returnValiePvalues = FALSE)
p |
Numeric vector, p values to be combined |
returnValiePvalues |
Logical, whether the valid p-values used should be returned as part of the list |
A FisherMethodResult
S3 object, a list of following elements
chisq: Chi-square statistic
df: Degree of freedom (which is twice the count of the valid p-values used for calculation)
p: p-value
validp (optional): valid p-values used for the calculation
The function returns the combined p-value using the sum of logs (Fisher's) method
The function was adapted from metap::sumlog
ps <- c(0.05, 0.75)
fishersMethod(ps)
fishersMethod(ps, returnValiePvalues=TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.