Unlimited learning, half price | 50% off

Last chance! 50% off unlimited learning

Sale ends in


RCy3 (version 1.2.0)

setNodeShapeRule: setNodeShapeRule

Description

Specify how data attributes -- the specified node attribute values -- determine the node shape.

Usage

setNodeShapeRule (obj, node.attribute.name=, attribute.values, node.shapes, default.shape)

Arguments

obj
a CytoscapeWindowClass object.
node.attribute.name
the node attribute whose values will determine the shape of each node when this rule is applied.
attribute.values
A list of scalar, discrete values. For instance, molecule types: 'transporter', 'receptor', 'kinase'
node.shapes
A list of nodes selected from among those supported.
default.shape
A single String, the shape used if no explicit mapping is provided.

Value

None.

See Also

setNodeColorRule setNodeLabelRule

Examples

Run this code
  # first, delete existing windows to save memory:
  deleteAllWindows(CytoscapeConnection())

  cw <- CytoscapeWindow ('setNodeShapeRule.test', graph=makeSimpleGraph())
  displayGraph (cw)
  layoutNetwork (cw, 'force-directed')
  shapes <- c("TRIANGLE", "ROUND_RECTANGLE", "ELLIPSE")
  molecule.types <- c("kinase", "transcription factor", "glycoprotein")
  setNodeShapeRule (cw, node.attribute.name='type', molecule.types, shapes)

Run the code above in your browser using DataLab