foresttopr

library(topr)

Single dataset

top_snps <- CD_UKBB %>% dplyr::filter(P<1e-18)
foresttopr(top_snps)

Two datasets

foresttopr(list(top_snps, CD_FINNGEN))

Use Gene_Symbol as the y-axis label

top_snps_genes <- top_snps %>% annotate_with_nearest_gene()

foresttopr(list(top_snps_genes, CD_FINNGEN),
           label_col="Gene_Symbol", 
           legend_labels=c("UKBB","FinnGen"))

Change the style

top_snps_genes <- top_snps %>% annotate_with_nearest_gene()

foresttopr(list(top_snps_genes, CD_FINNGEN),
           label_col="Gene_Symbol", 
           legend_labels=c("UKBB","FinnGen"),
           band_color="white", band_border_color="grey20", band_border_linewidth = 0.2)