Learn R Programming

coloc (version 3.2-1)

plot: Plotting functions for the coloc package

Description

You can plot objects of class coloc, colocBayes and colocABF

Plot results of a coloc.abf run

Usage

plot(x, y, ...)

# S4 method for colocTWAS,missing plot(x)

# S4 method for coloc,missing plot(x, y, ...)

# S4 method for colocABF,missing plot(x, y, ...)

# S4 method for coloc,missing plot(x, y, ...)

# S4 method for colocPCs,missing plot(x)

abf.plot(coloc.obj, Pos = 1:nrow(coloc.obj@results), chr = NULL, pos.start = min(Pos), pos.end = max(Pos), trait1 = "trait 1", trait2 = "trait 2")

Arguments

x

object to be plotted

y

ignored

...

other arguments

coloc.obj

object of class colocABF returned by coloc.abf()

Pos

positions of all snps in ds1 or in ds2

chr

Chromosome

pos.start

lower bound of positions

pos.end

upper bound of positions

trait1

name of trait 1

trait2

name of trait 2

Value

no return value

a ggplot object

Details

If coloc.obj is missing, it will be created as coloc.obj=coloc.abf(ds1,ds2). Both ds1 and ds2 should contain the same snps in the same order