make_parcutils_chip: Construct a parcutils_chip object

View source: R/chip_related.R

make_parcutils_chipR Documentation

Construct a parcutils_chip object

Description

This function creates an object of the parcutils_chip. parcutils_chip is an extension of the the RangedSummarizedExperiment. This object make sure that it contains necessary elements to perform downstream chipseq analysis. Downstream exploratory and visualization functions will be based on this object.

Usage

make_parcutils_chip(x, row_ranges)

Arguments

x

a list of the object(s) of normalisedMatrix.

row_ranges

an object of the class GenomicRanges. Each range must be identified by an unique id stored in a column name.

Details

RPM is calculated by the function RowSums applied on the each row of the normalized_matrix.

Value

an object of the class parcutils_chip. Class parcutils_chip extends to RangedSummarizedExperiment. It contains data in the below format

  • "assay" These are objects of the class NormalisedMatrix for each sample.

  • "columns" Columns are the columns in each assay. In this case they are the bins described in NormalisedMatrix.

  • "rowData" RPM value for each feature (row) across samples. For each feature RPM is the sum of all bins within a row.

Examples


signal = GRanges(seqnames = "chr1",
ranges = IRanges(start = c(1, 4, 7, 11, 14, 17, 21, 24, 27),
                 end = c(2, 5, 8, 12, 15, 18, 22, 25, 28)),
score = c(1, 2, 3, 1, 2, 3, 1, 2, 3))
target = GRanges(seqnames = "chr1", ranges = IRanges(start = 10, end = 20), name = "feat_1")
x = normalizeToMatrix(signal, target, extend = 10, w = 2)
rownames(x) <- "feat_1"
make_parcutils_chip(x, target)



cparsania/parcutils documentation built on Oct. 27, 2024, 4:55 a.m.