filter_low_var: Filtering genes with low variability

Description Usage Arguments Value Examples

View source: R/data_preprocessing.R

Description

Remove low variating genes based on the percentage given and the type of variation specified.

Usage

1
filter_low_var(data_expr, pct = 0.8, type = c("mean", "median", "mad"))

Arguments

data_expr

matrix or data.frame or SummarizedExperiment, table of expression values (either microarray or RNA-seq), with genes as column and samples as row

pct

float, percentage of gene to keep, value must be in ]0;1[

type

string, function name used for filtration. Should be either "mean", "median", or "mad"

Value

A data.frame of filtered genes

Examples

1
2
3
4
df <- matrix(abs(rnorm(15*45)), 15)
colnames(df) <- paste0("gene_", seq_len(ncol(df)))
rownames(df) <- paste0("sample_", seq_len(nrow(df)))
df_filtered <- filter_low_var(df)

GWENA documentation built on Feb. 17, 2021, 2:01 a.m.