display: Display a shiny interactive web interface to

Description Usage Arguments Value Author(s) Examples

View source: R/display.R

Description

Launches a shiny webpage for interactive viewing and analysis of the co-regulation network using a javascript cytoscape network.

Usage

1
display(coregnetwork, expressionData = NULL, TFA = NULL, alterationData = NULL, clinicalData = NULL, TFnotes = NULL, allTFplot = .heatplot, oneTFplot = .tfPlot)

Arguments

coregnetwork

A coregnet object

expressionData

A matrix or data.frame object with named columns (samples) and named rows (genes) containing gene expression data

TFA

A matrix or data.frame object with named columns (samples) and named rows (genes) containing transcription factor activity data such as the data obtained using the regulatorInfluence function. (unnecessary if expression data is given, makes the function run faster)

alterationData

optional. A matrix or data.frame object with named columns (samples) and named rows (genes) containing gene alteration data

clinicalData

optional. Either a list or a factor describing clinical information about samples. A list must be named and each entry should contain a vector of samples.

TFnotes

optional. A factor describing TFs.

allTFplot

A function ploting information by default. Default functions are implemented.

oneTFplot

A function ploting information about a TF which will be used when a single node is selected on the network. Default function are implemented.

Value

Does not return anything.

Author(s)

Remy Nicolle <remy.c.nicolle AT gmail.com>

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
acts=apply(matrix(rep(letters[1:4],7),nrow=2),2,paste,collapse=" ")[1:13]
reps=apply(matrix(rep(letters[5:8],7),nrow=2),2,paste,collapse=" ")[1:13]
grn=data.frame("Target"= LETTERS[1:26] ,"coact"=c(acts,reps),"corep"= c(reps,acts),"R2"=runif(26),stringsAsFactors=FALSE)
co=coregnet(grn)
samples= paste("S",1:100,sep="")
expression=matrix(rnorm(3400),ncol=100)
dimnames(expression) = list(c(grn$Target,names(regulators(co))),samples)

TFA = regulatorInfluence(co,expression,minTarg=4)
colnames(TFA) = samples
if(interactive()){
 display(co,TFA=TFA,expressionData=expression)
}

CNA =matrix( sample(-2:2,800,replace=TRUE),ncol=100)
dimnames(CNA) = list(names(regulators(co)),samples)
if(interactive()){
  display(co,TFA=TFA,expressionData=expression,alteration=CNA)
}

clinicGrp = factor(paste("grp",sample(1:3,100,replace=TRUE),sep=""))
names(clinicGrp) =samples
if(interactive()){
 display(co,TFA=TFA,expressionData=expression,alteration=CNA,clinicalData=clinicGrp)
}

Example output

Loading required package: igraph

Attaching package: 'igraph'

The following objects are masked from 'package:stats':

    decompose, spectrum

The following object is masked from 'package:base':

    union

Loading required package: shiny
Loading required package: arules
Loading required package: Matrix

Attaching package: 'arules'

The following objects are masked from 'package:base':

    abbreviate, write

Warning message:
system call failed: Resource temporarily unavailable 

CoRegNet documentation built on Nov. 8, 2020, 5:06 p.m.