trackdata: Access Track Data

Description Usage Arguments Value Examples

Description

Access and modify the track data. x$name and x$name <- value are just shortcuts for trackData(x)$name and trackData(x)$name <- value, respectively.

Usage

1
2
3
4
5
6
7
8
9
trackData(x)

trackData(x) <- value

## S4 method for signature 'TnTTrack'
x$name

## S4 replacement method for signature 'TnTTrack'
x$name <- value

Arguments

x

A TnTTrack object.

value

Replaced value.

name

Passed to the inner method for track data.

Value

trackData on all track types except "CompositeTrack" returns an object that inherits GRanges class, which means they should behave like a GRanges. While trackData on "CompositeTrack" returns a list of tracks.

Examples

1
2
3
4
5
6
track <- BlockTrack(GRanges("chr1", IRanges(6, 54)))
class(trackData(track)) # track data of block track is an object that inherits GRanges.
#trackData(track)
ctrack <- merge(track, track)
class(trackData(ctrack)) # track data of composite track is a list of tracks
#trackData(ctrack)

TnT documentation built on Nov. 8, 2020, 8:11 p.m.