CoverageSequenceData implements SequenceData to contain and aggregate the coverage of reads per position along the transcripts.

CoverageSequenceData contains one column per data file named using the following naming convention coverage.condition.replicate.

aggregate calculates the mean and sd for samples in the control and treated condition separatly.

CoverageSequenceDataFrame(
  df,
  ranges,
  sequence,
  replicate,
  condition,
  bamfiles,
  seqinfo
)

CoverageSequenceData(bamfiles, annotation, sequences, seqinfo, ...)

# S4 method for CoverageSequenceData,BamFileList,GRangesList,XStringSet,ScanBamParam
getData(x, bamfiles, grl, sequences, param, args)

# S4 method for CoverageSequenceData
aggregateData(x, condition = c("Both", "Treated", "Control"))

# S4 method for CoverageSequenceData
getDataTrack(x, name, ...)

Arguments

df, ranges, sequence, replicate

inputs for creating a SequenceDataFrame. See SequenceDataFrame.

condition

For aggregate: condition for which the data should be aggregated.

bamfiles, annotation, seqinfo, grl, sequences, param, args, ...

See SequenceData

x

a CoverageSequenceData

name

For getDataTrack: a valid transcript name. Must be a name of ranges(x)

Value

a CoverageSequenceData object

Examples

# Construction of a CoverageSequenceData objectobject
library(RNAmodR.Data)
#> Loading required package: ExperimentHub
#> Loading required package: AnnotationHub
#> Loading required package: BiocFileCache
#> Loading required package: dbplyr
#> Loading required package: ExperimentHubData
#> Loading required package: AnnotationHubData
#> Warning: replacing previous import 'utils::findMatches' by 'S4Vectors::findMatches' when loading 'ExperimentHubData'
library(rtracklayer)
#> 
#> Attaching package: 'rtracklayer'
#> The following object is masked from 'package:AnnotationHub':
#> 
#>     hubUrl
annotation <- GFF3File(RNAmodR.Data.example.man.gff3())
#> see ?RNAmodR.Data and browseVignettes('RNAmodR.Data') for documentation
#> loading from cache
sequences <- RNAmodR.Data.example.man.fasta()
#> see ?RNAmodR.Data and browseVignettes('RNAmodR.Data') for documentation
#> loading from cache
#> require("Rsamtools")
files <- c(treated = RNAmodR.Data.example.wt.1())
#> see ?RNAmodR.Data and browseVignettes('RNAmodR.Data') for documentation
#> loading from cache
csd <- CoverageSequenceData(files, annotation = annotation,
                            sequences = sequences)
#> Import genomic features from the file as a GRanges object ... 
#> OK
#> Prepare the 'metadata' data frame ... 
#> OK
#> Make the TxDb object ... 
#> OK
#> Loading Coverage data from BAM files ... 
#> OK