crosstalkNetwork: Generate a network containing the top-performing pathway...

View source: R/crosstalkNetwork.R

crosstalkNetworkR Documentation

Generate a network containing the top-performing pathway pairs.

Description

Generates a glmnet binomial classification model for a given matrix of pathway-pair discriminating scores and outputs a network object containing the top-performing pathway pairs in the model.

Usage

crosstalkNetwork(
  crosstalk_matrix,
  groups,
  alpha = 1,
  lambda = "best",
  output_network = TRUE,
  output_model = FALSE
)

Arguments

crosstalk_matrix

A matrix of discriminating scores in which each column is a pair of enriched pathways and each row is a sample. The output of pathwayCrosstalk().

groups

A dataframe containing the mappings between sample identifiers ('sample_id', a factor with the reference condition as the first level) and associated treatment conditions ('group'). The sample identifiers must be in the same order as the columns of the count_matrix.

alpha

The alpha value applied to the glmnet classification model. Use alpha = 1 for lasso regression and alpha = 0 for ridge regression.

lambda

The lambda value applied to the glmnet classification model.

output_network

Logical. If TRUE, the function outputs the network object.

output_model

Logical. If TRUE, the function outputs the model.

Value

Depending on the values of the 'output_network' and 'model_evaluation' arguments, either a list containing the network object or a list containing the model evaluation metrics.


hemoshear/pathwayTalk documentation built on July 16, 2022, 12:09 a.m.