Skip to contents

This function is a wrapper around ggfastman::fast_manhattan which allows for the creation of a Manhattan plot from a dataframe containing GWAS summary statistics.

Usage

gg_manhattan_df(
  sumstats_df,
  annotation_df = NULL,
  chr_col = chromosome,
  pos_col = position,
  pval_col = p_value,
  pval_threshold = 0.001,
  label_col = gene,
  build = "hg19",
  color1 = "#045ea7",
  color2 = "#82afd3",
  speed = "slow",
  ...
)

Arguments

sumstats_df

Dataframe containing GWAS summary statistics

annotation_df

Optional dataframe containing chromosome, position, and annotation labels

chr_col

Name of chromosome column

pos_col

Name of position column

pval_col

Name of p-value column

pval_threshold

Threshold for plotting p-values (p-values greater than this value are excluded from the plot; default = 0.001)

label_col

Name of column in annotation_df containing annotations to include on the plot

build

(string) One of "hg18", "hg19", or "hg38" (passed to ggfastman)

color1

(string) Color for odd-numbered chromosomes (passed to ggfastman)

color2

(string) Color for even-numbered chromosomes (passed to ggfastman)

speed

(string) One of "slow", "fast", or "ultrafast"; passed to ggfastman to control plotting speed

...

Arguments passed to ggfastman::fast_manhattan

Value

A ggplot2 object

See also

Other plotting: gg_qq_df()

Examples

if (FALSE) {
gg_manhattan_df(sumstats_df)
}