CalcPathSig: Calculate the pathway activity signature (PAS)

Description Usage Arguments Value Examples

View source: R/CalcPathSig.R

Description

Calculate the pathway activity signature (PAS)

Usage

1
CalcPathSig(EdgeFrom,EdgeTo,interaction,AdjMat=NULL,ncomp=NULL,data,ntop=100,neigen=NULL)

Arguments

EdgeFrom

A character vector of gene symbols of one end of the edges. This parameter is ignored if AdjMat is specified.

EdgeTo

A character vector of gene symbols of the other end of the edges. This parameter is ignored if AdjMat is specified.

interaction

A numeric vector with components of 1 and -1 to denote activation and inhibition for the edges. This parameter is ignored if AdjMat is specified.

AdjMat

The signed undirected adjacency matrix for the pathway topology.

ncomp

The pre-specified number of sub-graphs used to calculate the consistency score. Default is using all sub-graphs.

data

A data frame of gene expression levels, with rows for profile genes and columns for perturbed pathway genes/proteins (column names are the perturbed gene/protein symbols).

ntop

The number of signature genes used to calculate the PAS. Default is 100.

neigen

The maximum number of eigen sub-spaces used to calculate gene scores. Default is using all eigen sub-spaces.

Value

The PAS is returned as a data frame with two columns. The first column is the annotations of the signature genes, and the second column is the pathway activity scores.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
# load data
downloadLINCS("LincsCGS")
Data <- LincsCGS$MCF7

# obtain edge information of a pathway
Edges <- AllEdges[AllEdges$Pathway=="hsa04150",]

# calculate pathway signature by specifying edge information
CalcPathSig(EdgeFrom=Edges$GeneSymbol_a,EdgeTo=Edges$GeneSymbol_b,interaction=Edges$Interaction,data=Data,neigen=1)

# calculate pathway signature by specifying adjacency matrix
AdjMat <- CalcAdj(EdgeFrom=Edges$GeneSymbol_a,EdgeTo=Edges$GeneSymbol_b,interaction=Edges$Interaction)
CalcPathSig(AdjMat=AdjMat,data=Data,neigen=1)

uc-bd2k/paslincs documentation built on May 28, 2020, 8:20 a.m.