rich_wider: rich_wider

Description Usage Arguments

View source: R/rich_utils.R

Description

Given a dataframe generate by rich_aggregate, filters it to get a specific 'gs', it calculates negative 'log10(p.norm) * sign of NES', filters out all 'FDR.q.val > fdr_threshold' and returns a wider datagrame with 'pathways' as rows, 'contrasts' as column and one of the columns as the 'value'. When a combination of contrast-pathway is not presence a 0 is substituted to NA when pivoting.

Usage

1
rich_wider(dat, fdr_threshold, gs, value = "n_logp_sign")

Arguments

dat

Dataframe as returned by rich_aggregate.

fdr_threshold

Minimum 'FDR.q.val' to keep.

gs

Gene Set Database.

value

Column from which to take the value for pivit wider. One of c("fdr_q_val", "nes", "nom_p_val", "n_logp_sign"). Defaut is "n_logp_sign".


c1au6i0/richcleaner documentation built on Dec. 31, 2020, 9:01 p.m.