Learn R Programming

DiffLogo (version 1.2.1)

diffLogo: Draw DiffLogo

Description

Draws the difference of two sequence logos.

Usage

diffLogo(diffLogoObj, ymin = 0, ymax = 0, sparse = FALSE)

Arguments

diffLogoObj
a DiffLogoObject created by the function createDiffLogoObject
ymin
minimum value on the y-axis
ymax
maximum value on the y-axis
sparse
if TRUE margins are reduced and tickmarks are removed from the logo

Examples

Run this code
motif_folder= "extdata/pwm"
motif_names = c("HepG2","MCF7","HUVEC","ProgFib")
motifs = list()
for (name in motif_names) {
  fileName = paste(motif_folder,"/",name,".txt",sep="")
  file = system.file(fileName, package = "DiffLogo")
  motifs[[name]] = as.matrix(read.delim(file,header=FALSE))
}

pwm1 = motifs[[motif_names[[1]]]]
pwm2 = motifs[[motif_names[[2]]]]

diffLogoObj = createDiffLogoObject(pwm1 = pwm1, pwm2 = pwm2)
diffLogo(diffLogoObj)

Run the code above in your browser using DataLab