generateStatsSummary: Generate a summary PDF for the number of connections for a...

View source: R/core.R

generateStatsSummaryR Documentation

Generate a summary PDF for the number of connections for a GRN object.

Description

Essentially, this functions calls filterGRNAndConnectGenes repeatedly and stores the total number of connections and other statistics each time to summarize them afterwards. All arguments are identical to the ones in filterGRNAndConnectGenes, see the help for this function for details.

Usage

generateStatsSummary(
  GRN,
  TF_peak.fdr = c(0.001, 0.01, 0.05, 0.1, 0.2),
  TF_peak.connectionTypes = "all",
  peak_gene.fdr = c(0.001, 0.01, 0.05, 0.1, 0.2),
  peak_gene.p_raw = NULL,
  peak_gene.r_range = c(0, 1),
  gene.types = c("protein_coding", "lincRNA"),
  allowMissingGenes = c(FALSE, TRUE),
  allowMissingTFs = c(FALSE),
  forceRerun = FALSE
)

Arguments

GRN

Object of class GRN

TF_peak.fdr

Numeric vector. Default c(0.001, 0.01, 0.05, 0.1, 0.2). TF-peak FDR values to iterate over.

TF_peak.connectionTypes

Character vector. Default all. TF-peak connection types to consider. The special keyword all denotes all connection types (e.g., expression and TFActivity) that are found in the GRN object. By default, only expression is present in the object, so all and expression are usually equivalent unless calculation of TF-peak links based on TF activity has also been enabled.

peak_gene.fdr

Numeric vector. Default c(0.001, 0.01, 0.05, 0.1, 0.2). Peak-gene FDR values to iterate over.

peak_gene.p_raw

Numeric vector. Default NULL. Peak-gene raw p-value values to iterate over. Skipped if set to NULL.

peak_gene.r_range

Numeric vector of length 2 (minimum -1, maximum 1). Default c(0,1). The correlation range of peak-gene connections to keep.

gene.types

Character vector of supported gene types. Default c("protein_coding", "lincRNA"). Filter for gene types to retain, genes with other gene types are filtered.

allowMissingGenes

Logical vector. Default c(FALSE, TRUE). Allow genes to be missing for peak-gene connections?

allowMissingTFs

Logical vector. Default c(FALSE). Allow TFs to be missing for TF-peak connections?

forceRerun

TRUE or FALSE. Default FALSE. Force execution, even if the GRN object already contains the result. Overwrites the old results.

Value

The same GRN object, with added data from this function.

Examples

# See the Workflow vignette on the GRaNIE website for examples
GRN = loadExampleObject()
GRN = generateStatsSummary(GRN, TF_peak.fdr = c(0.01, 0.1), peak_gene.fdr = c(0.01, 0.1))


chrarnold/GRaNIE documentation built on April 28, 2022, 2:18 a.m.