fast_qq | R Documentation |
This is a very fast plotting function for quantile-quantile (QQ) plots using ggplot2
and scattermore
functionalities.
fast_qq(
pvalue,
speed = "fast",
pointsize = 1.2,
linecolor = "deeppink",
ci_color = "steelblue",
ci_alpha = 0.3,
conf.alpha = 0.05,
confint = T,
log10 = T,
inflation_method = "median",
title = "QQ-plot"
)
pvalue |
A numeric vector of pvalues. |
speed |
The speed option. Fast and ultrafast use scattermore functionality |
pointsize |
Only when using the 'fast' option you can increase pointsize. Default is 1.2 |
linecolor |
Color of the abline of the theoretical and sample distributions. |
ci_color |
Color fof the confidence interval |
ci_alpha |
Alpha value (e.g. transparency) of the confidence's fill color |
conf.alpha |
Alpha level of the confidence interval. Default value = 0.05 |
confint |
Print a confident interval. Default = TRUE |
log10 |
Should the pvalues -log10 tranformed? Default = TRUE |
inflation_method |
Method to calculate the genomic inflation factor. choices = c("median","regression"). The "median" method is the most common way to estimate lambda. The regression method is adapted from the GenABEL package. |
title |
A title added to the plot |
A ggplot2 object/plot
data("gwas_data")
head(gwas_data)
fast_qq(gwas_data$pvalue, inflation_method = "reg")
fast_qq(gwas_data$pvalue, inflation_method = "med")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.