mergeReplicates: Merge GRanges that are of replicate experiments.

mergeReplicatesR Documentation

Merge GRanges that are of replicate experiments.

Description

A lane of next generation sequencing data can be stored as a GRanges object. Sometimes, a GRangesList of various lanes can have experimental replicates. This function allows the merging of such elements.

Usage

  ## S4 method for signature 'GRangesList'
mergeReplicates(reads, types, verbose = TRUE)

Arguments

reads

A GRangesList.

types

A vector the same length as reads, that gives what type of experiment each element is of.

verbose

Whether to print the progess of processing.

Details

The experiment type that each element of the merged list is of, is stored in the first element of the metadata list.

Value

A GRangesList with one element per experiment type.

Author(s)

Dario Strbenac

Examples

  library(GenomicRanges)
  grl <- GRangesList(GRanges("chr1", IRanges(5, 10)),
                     GRanges("chr18", IRanges(25, 50)),
                     GRanges("chr22", IRanges(1, 100)))
  antibody <- c("MeDIP", "MeDIP", "H3K4me3")
  mergeReplicates(grl, antibody)

markrobinsonuzh/Repitools documentation built on March 20, 2024, 6:04 a.m.