filter_counts: Filter count matrix

View source: R/filter_counts.R

filter_countsR Documentation

Filter count matrix

Description

Remove features with zero counts and less than the low count cutoff. The default method is a maximum-based filter where every sample is less than or equal to the low count cutoff.

Usage

filter_counts(count_tbl, n = 1, sum = FALSE)

Arguments

count_tbl

a count matrix, data.frame or tibble

n

low count cutoff, default 1

sum

Use total read counts instead of the maximum.

Value

A count matrix

Author(s)

Chris Stubben

Examples

c1 <- matrix(c(0,0,0,2,12,0,0,1,1,0,0,1,1,1,0), ncol=3)
c1
filter_counts(c1)
filter_counts(c1, sum=TRUE)

HuntsmanCancerInstitute/hciR documentation built on Dec. 10, 2024, 12:22 p.m.