correlationPlot The correlationPlot can be used to vizualize e.g. the correlation between the mean binding intensity of specific
regions around annotated features and gene expression. The regions around the annotated features, that should be analyzed are defined
in a data frame. Each row represents one region. In the upper panel of the plot, the correlation is plotted in a barplot. In the lower
panel, the annotated feature and the regions defined in the data frame are shown.
a data frame, containing four columns. Every row defines one region to be analyzed and is plotted in the lower panel. pos=start, upstream=500 and downstream=500 mean characterize the region 500 bp upstream and downstream around the start of the feature. The pos columns is a character with values out of c("start", "region", "end"). upstream and downstream ar integers, indicating how many bases upstream and downstream from the specified position in the feature are included. level is an integer, that says at which level the rectangle in the lower device should be plotted. The numeration goes from the bottom to the ceiling. cor is the correlation of the region, which is plotted in the upper panel.
labels
a character vector which holds the names of the borders of the annotated region. (e.g. c("TSS", "TTS") for transcripts)
...
parameters, that are passed to barplot (for plotting the upper panel)
R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
> library(Starr)
Loading required package: Ringo
Loading required package: Biobase
Loading required package: BiocGenerics
Loading required package: parallel
Attaching package: 'BiocGenerics'
The following objects are masked from 'package:parallel':
clusterApply, clusterApplyLB, clusterCall, clusterEvalQ,
clusterExport, clusterMap, parApply, parCapply, parLapply,
parLapplyLB, parRapply, parSapply, parSapplyLB
The following objects are masked from 'package:stats':
IQR, mad, xtabs
The following objects are masked from 'package:base':
Filter, Find, Map, Position, Reduce, anyDuplicated, append,
as.data.frame, cbind, colnames, do.call, duplicated, eval, evalq,
get, grep, grepl, intersect, is.unsorted, lapply, lengths, mapply,
match, mget, order, paste, pmax, pmax.int, pmin, pmin.int, rank,
rbind, rownames, sapply, setdiff, sort, table, tapply, union,
unique, unsplit
Welcome to Bioconductor
Vignettes contain introductory material; view with
'browseVignettes()'. To cite Bioconductor, see
'citation("Biobase")', and for packages 'citation("pkgname")'.
Loading required package: RColorBrewer
Loading required package: limma
Attaching package: 'limma'
The following object is masked from 'package:BiocGenerics':
plotMA
Loading required package: Matrix
Loading required package: grid
Loading required package: lattice
Loading required package: affy
Attaching package: 'affy'
The following object is masked from 'package:Ringo':
probes
Loading required package: affxparser
Attaching package: 'Starr'
The following object is masked from 'package:affy':
plotDensity
The following object is masked from 'package:limma':
plotMA
The following object is masked from 'package:BiocGenerics':
plotMA
> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/Starr/correlationPlot.Rd_%03d_medium.png", width=480, height=480)
> ### Name: correlationPlot
> ### Title: correlation of ChIP signals to other data
> ### Aliases: correlationPlot
> ### Keywords: hplot
>
> ### ** Examples
>
> ## Constructing an example data frame
> pos <- c("start", "start", "start", "region", "region","region","region", "stop","stop","stop")
> upstream <- c(500, 0, 250, 0, 0, 500, 500, 500, 0, 250)
> downstream <- c(0, 500, 250, 0, 500, 0, 500, 0, 500, 250)
> level <- c(1, 1, 2, 3, 4, 5, 6, 1, 1, 2)
> cor <- seq(-1,1, length=10)
> info <- data.frame(pos=pos, upstream=upstream, downstream=downstream, level=level, cor=cor, stringsAsFactors=FALSE)
> rownames(info) <- letters[1:10]
>
> ## Generate plot
> correlationPlot(info)
>
>
>
>
>
> dev.off()
null device
1
>