plotClusters {Repitools} | R Documentation |
Given an annotation of gene positions that has a score column, the function will make a series of bar chart plots, one for each cluster.
## S4 method for signature 'data.frame' plotClusters(x, s.col = NULL, non.cl = NULL, ...) ## S4 method for signature 'GRanges' plotClusters(x, s.col = NULL, non.cl = NULL, ...)
x |
A summary of genes and their statistical score, and the cluster that
they belong to. Either a |
s.col |
The column number of the |
non.cl |
The value in the cluster column that represents genes that are not in any cluster |
... |
Further parameters to be passed onto |
A plot for each cluster is made. Therefore, the PDF device should be opened before this function is called.
Dario Strbenac
library(GenomicRanges) g.summary <- GRanges("chr1", IRanges(seq(1000, 10000, 1000), width = 100), rep(c('+', '-'), 5), `t-statistic` = rnorm(10, 8, 2), cluster = c(0, 0, 0, 0, 0, 1, 1, 1, 1, 0), name = paste("Gene", 1:10)) plotClusters(g.summary, 1, 0, ylim = c(4, 12), lwd = 5)