HighlightTrack-class | R Documentation |
A container for other track objects from the Gviz package that allows for the addition of a common highlighting area across tracks.
## S4 method for signature 'HighlightTrack'
initialize(.Object, trackList, ...)
HighlightTrack(
trackList = list(),
range = NULL,
start = NULL,
end = NULL,
width = NULL,
chromosome,
genome,
name = "HighlightTrack",
...
)
## S4 replacement method for signature 'HighlightTrack,list'
displayPars(x, recursive = FALSE) <- value
## S4 method for signature 'HighlightTrack'
length(x)
## S4 replacement method for signature 'HighlightTrack'
chromosome(GdObject) <- value
## S4 method for signature 'HighlightTrack'
setStacks(GdObject, ...)
## S4 method for signature 'HighlightTrack'
consolidateTrack(GdObject, chromosome, ...)
## S4 method for signature 'HighlightTrack'
subset(x, ...)
## S4 method for signature 'HighlightTrack'
show(object)
.Object |
.Object |
trackList |
A list of Gviz track objects that all have to inherit from
class |
... |
All additional parameters are ignored. |
range |
An optional meta argument to handle the different input types. If the
The different input options for
|
start, end |
An integer scalar with the genomic start or end coordinates
for the highlighting range. Can also be supplied as part of the |
width |
An integer vector of widths for highlighting ranges. This can
be used instead of either |
chromosome |
The chromosome on which the track's genomic ranges are
defined. A valid UCSC chromosome identifier if
|
genome |
The genome on which the track's ranges are defined. Usually
this is a valid UCSC genome identifier, however this is not being formally
checked at this point. If not provided here the constructor will try to
extract this information from the provided inputs, and eventually will fall
back to the default value of |
name |
Character scalar of the track's name. This is not really used and only exists fro completeness. |
x |
A valid track object class name, or the object itself, in which case the class is derived directly from it. |
recursive |
|
value |
Value to be set. |
GdObject |
Object of |
object |
object |
A track to conceptionally group other Gviz track objects into a meta track
for the sole purpose of overlaying all the contained tracks with the same
highlighting region as defined by the objects genomic ranges. During
rendering the contained tracks will be treated as if they had been provided
to the plotTracks
function as individual objects.
The return value of the constructor function is a new object of class
HighlightTrack
.
initialize(HighlightTrack)
: Initialize.
HighlightTrack()
: Constructor function for
HighlightTrack-class
.
displayPars(x = HighlightTrack) <- value
: set display parameters using the values of
the named list in value. See settings
for details on display
parameters and customization.
length(HighlightTrack)
: return the number of subtracks.
chromosome(HighlightTrack) <- value
: replace the value of the track's chromosome.
This has to be a valid UCSC chromosome identifier or an integer or character
scalar that can be reasonably coerced into one.
setStacks(HighlightTrack)
: Rrecompute the stacks based on the available
space and on the object's track items and stacking settings.
This really just calls the setStacks
methods for the contained tracks and
only exists for dispatching reasons.
consolidateTrack(HighlightTrack)
: Consolidate
For a HighlightTrack
apply the method on each of the subtracks in
the trackList
slot
subset(HighlightTrack)
: subset all the contained tracks in an HighlightTrack by coordinates and sort if necessary.
show(HighlightTrack)
: Show method.
Objects can be created using the constructor function HighlightTrack
.
Florian Hahne
DisplayPars
GdObject
GRanges
HighlightTrack
ImageMap
IRanges
RangeTrack
DataTrack
collapsing
grouping
panel.grid
plotTracks
settings
## Object construction:
set.seed(123)
dat <- runif(100, min = -2, max = 22)
gt <- GenomeAxisTrack()
dt <- DataTrack(data = dat, start = sort(sample(200, 100)), width = 1, genome = "hg19")
ht <- HighlightTrack(trackList = list(gt, dt))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.