Description Usage Arguments Value Author(s) Examples
Estimate the inflation factor for a distribution of P-values or 1-df chi-square test using a permutation-based NULL distribution of P-values provided by the package/user. The implementation is similar to the default (estlambda) implementation in R package GenABEL but here it does not assume the NULL distribution of P-values to be uniform. Rather it estimates lambda inflation factor by comparing to the permutation-based expected NULL distribution as described for QQ plots. This is thus more representative of the true NULL distribution of Fisher's Exact p-values for the given case-control configuration in a study.
1 |
p.o |
Observed P-values from the data (true case/control assignments). |
p.e |
Expected P-values from the NULL distribution, usually obtained through label permutations of the matrix data. |
plot |
Indicate if a plot should be produced. |
filter |
Indicate if the filter should be applied. This parameter behaves the same as in estlambda in GenABEL. |
adjust.xy |
Indicate if the x-axis and y-axis should be adjusted to their own range. |
... |
Additional arguments passed to the plot function. |
Returns a list containing the permutation-based estimated lambda value (estimate) and its standard error (se).
Slave Petrovski and Quanli Wang
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | #load pre-computed p-values for IGM dataset
library(QQperm)
data("example.Ps")
#print output to pdf file only if not running in interactive mode
if (!interactive()) {
pdf("lambda.pdf")
}
#estimate inflation factor and generate plot.
lambda <-estlambda2(example.Ps$observed,example.Ps$perm, plot = TRUE, adjust.xy = TRUE)
if (!interactive()) {
dev.off()
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.