filterBins: Feature filtration

View source: R/snap-utilities.R

filterBinsR Documentation

Feature filtration

Description

This function takes a snap obj as input and perform feature selection in the following manner: 1) calculate coverage of each genomic bin/feature; 2) log scale the coverage by log10(count + 1); 3) the log-nromal distribution is then converted into zscore; 4) bins with zscore beyond [low.threshold, high.threshold] are filtered;

Usage

filterBins(obj, low.threshold, high.threshold, mat)

Arguments

obj

A snap obj

low.threshold

Low cutoffs for the parameters (default is -2)

high.threshold

High cutoffs for the parameters (default is 2)

mat

Matrix to filter c("bmat", "pmat")

Value

Returns a snap obj

Examples

data(demo.sp);
filterBins(
obj=demo.sp, 
low.threshold=-2,
high.threshold=2
);


r3fang/SnapATAC documentation built on March 29, 2022, 4:33 p.m.