Skip to contents

Object ccGenomicTrack will call the function circlize::circos.genomicTrackPlotRegion while drawing.

Usage

ccGenomicTrack(...)

Arguments

...

Arguments passed on to circlize::circos.genomicTrackPlotRegion

data

A bed-file-like data frame or a list of data frames

ylim

If it is NULL, the value will be calculated from data. If stack is set to TRUE, this value is ignored.

stack

whether to plot in a "stack" mode.

numeric.column

Columns of numeric values in data that will be used for plotting. If data is a data frame list, numeric.column should be either length of one or length of data. If value of numeric.column is not set, its value will depend on the structure of data. If data is a data frame, the default value for numeric.column is all the numeric column starting from the fourth column. If data is a list of data frame, the default value for numeric.column is a vector which have the same length as data and the value in default numeric.column is the index of the first numeric column in corresponding data frame.

jitter

Numeric. Only works for adding points in circos.genomicTrackPlotRegion under stack mode

panel.fun

Self-defined function which will be applied on each sector. Please not it is different from that in circos.trackPlotRegion. In this function, there are two arguments (region and value) plus .... In them, region is a two-column data frame with start positions and end positions in current genomic category (e.g. chromosome). value is a data frame which is derived from data but excluding the first three columns. Rows in value correspond to rows in region. ... is mandatory and is used to pass internal parameters to other functions. The definition of value will be different according to different input data (data frame or list of data frame) and different settings (stacked or not), please refer to 'details' section and vignettes to detailed explanation.

Value

Object ccGenomicTrack

Examples

library(circlizePlus)
cc = ccPlot(initMode = "initializeWithIdeogram",chromosome.index = "chr1", plotType = NULL)
bed = generateRandomBed(nr = 300)
t1 = ccGenomicTrack(bed, panel.fun = function(region, value, ...) {
  circos.genomicPoints(region, value, pch = 16, cex = 0.5, ...)
})
cc+t1

circos.clear()