apheman: apheman

Description Usage Arguments Value See Also Examples

View source: R/apheman.R

Description

Create Manhattan plots for PheWAS

Usage

1
2
3
4
5
apheman(d, phegroup, line, log10 = TRUE, yaxis, ymax, opacity = 1,
  annotate_snp, annotate_p, highlight_snp, highlight_p, highlighter = "red",
  title = NULL, chrcolor1 = "#AAAAAA", chrcolor2 = "#4D4D4D", groupcolors,
  background = "variegated", chrblocks = TRUE, file = "apheman",
  ext = "gif", hgt = 800, wi = 1300)

Arguments

d

data frame, must contain PHE, SNP, CHR, POS, pvalue, Frame columns, optional Shape

phegroup

optional grouping file for phenotypes, must contain PHE and Group columns

line

optional pvalue threshold to draw red line at

log10

plot -log10() of pvalue column, boolean

yaxis

label for y-axis, automatically set if log10=TRUE

ymax

set the upper limit for the y-axis if not automatically scaled

opacity

opacity of points, from 0 to 1, useful for dense plots

annotate_snp

vector of SNPs to annotate

annotate_p

pvalue threshold to annotate

highlight_snp

vector of SNPs to highlight

highlight_p

pvalue threshold to highlight

highlighter

color to highlight

title

optional string for plot title

chrcolor1

first alternating color for chromosome

chrcolor2

second alternating color for chromosome

groupcolors

named vector of colors for data in 'Color' column

background

variegated or white

chrblocks

boolean, turns on x-axis chromosome marker blocks

file

file name of saved image

ext

file type to save, "gif" or "mp4"

hgt

height of plot in pixels

wi

width of plot in pixels

Value

.gif or .mp4 file

See Also

pheman, ipheman, agman, aeman

Other PheWAS functions: ipheman, pheman

Other animated plotting functions: aeman, agman

Examples

1
2
3
4
5
#We can duplicate the PHE column so that each
#phenotype will be a frame
data(phewas)
phewas$Frame <- phewas$PHE
apheman(phewas, line=0.001, title="PheWAS Example:")

anastasia-lucas/plotman documentation built on July 13, 2020, 11:47 p.m.