load_deeptoolsmatrix3_new: load_deeptoolsmatrix3_new

Description Usage Arguments Details Value Examples

View source: R/deeptools_funs.R

Description

Loads a deeptools v3 matrix file new version.

Usage

1
load_deeptoolsmatrix3_new(fname, na.fill)

Arguments

fname

the file to load.

na.fill

Fills NAs with this value zero. Default is NA.

Details

Always returns and S3 object. Loads a gzipped deeptools matrix file and collects this in a metagene object, with slots: $header, $regions, $samples, $groups and $matrices. Where $header contains the header information as a named vector. Matrices is a list of matrices where each matrix is specific to 1 sample and 1 group. $samples are the samplenames for each matrix. $groups are the groups for each matrix. $rel_pos is the list of relative positions to anchorpoint for each group. Names are the group names. $regions same as rel_pos are the region names (ie col4 of bed file).

Value

An object of class metagene.

Examples

1
2
3
4
5
6
7
8
 fname <- system.file("extdata", "deeptools3_matrix.gz", package = "RMetaTools")
 m <- load_deeptoolsmatrix3_new(fname)
 m$header
 m$samples
 m$groups
 lapply(m$rel_pos, head)
 lapply(m$regions, head)
 lapply(m$matrices, dim)

manschmi/RMetaTools documentation built on Dec. 14, 2021, 4:33 a.m.