cyPlot: cyPlot

Description Usage Arguments Value Author(s) Examples

Description

Given a node attribute data frame (node.df) with the node names in column 1, and an edge attribute data.frame (edge.df) with node names in the first two columns, cyPlot creates a graphNEL object with nodes, edges, and their attributes that can be loaded into Cytoscape with CytoscapeWindow.

Usage

1
cyPlot(node.df, edge.df)

Arguments

node.df

a data.frame with node names in the first column.

edge.df

a data.frame with node names in the first two columns.

Value

a graphNEL object with nodes, edges, and their attributes

Author(s)

Mark Grimes

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
  ## Not run: 
  # first, delete existing windows to save memory:
  deleteAllWindows(CytoscapeConnection())

	# Create node and edge data frames
  node.tbl <- data.frame(Gene.Name=c("FOX", "CENT", "RTK"), Numeric.Data=as.numeric(c(10, 12, 7)), nodeType=c("ts factor", "nuclear porin", "receptor"))
  edge.tbl <- data.frame(Gene.1=c("FOX", "FOX", "CENT", "CENT"), Gene.2=c("CENT", "RTK", "FOX", "RTK"), Weight=as.numeric(c(0.1, 1, 2, 0.02)), edgeType="interaction")
  window.name <- 'demo cyPlot'
	# Create graph and send to Cytoscape
  cg <- cyPlot(node.tbl, edge.tbl)
  cw <- CytoscapeWindow (window.name, graph=cg)
  displayGraph (cw)
  redraw (cw)
  layoutNetwork(cw)

## End(Not run)

tmuetze/Bioconductor_RCy3_the_new_RCytoscape documentation built on May 31, 2019, 4:39 p.m.