setEdgeTargetArrowOpacityDirect: setEdgeTargetArrowOpacityDirect

Description Usage Arguments Value Author(s) See Also Examples

Description

In the specified CytoscapeWindow, set the opacity of the target arrow of the specified edge or edges. Opacity is an integer between 0 (invisible) and 255 (fully rendered).

Usage

1
setEdgeTargetArrowOpacityDirect(obj, edge.names, new.values)

Arguments

obj

a CytoscapeWindowClass object.

edge.names

one or more cy2-style edge names, String objects.

new.values

one or more integer objects, between 0 and 255.

Value

None.

Author(s)

Paul Shannon

See Also

cy2.edge.names setEdgeTargetArrowOpacityDirect

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
26
27
28
29
  cw <- new.CytoscapeWindow ('setEdgeTargetArrowOpacityDirect.test', graph=makeSimpleGraph())
  displayGraph (cw)
  layoutNetwork(cw, 'jgraph-spring')
  redraw (cw)

  edges.of.interest = as.character (cy2.edge.names (cw@graph))

     # make sure the target arrows are visible
  setEdgeTargetArrowShapeDirect (cw, edges.of.interest, 'Circle')

    # first try passing three edges and three arrow opacity values
  setEdgeTargetArrowOpacityDirect (cw, edges.of.interest, c (64, 128, 255))
  redraw (cw)
  
    # now try passing three edges and one opacity value
  setEdgeTargetArrowOpacityDirect (cw, edges.of.interest, 32)
  redraw (cw)

    # now loop through all of the arrow.opacitys

  for (opacity in seq (0, 255, by=45)) {
    setEdgeTargetArrowOpacityDirect (cw, edges.of.interest, opacity)
    redraw (cw)
    }


    # restore the default
  setEdgeTargetArrowOpacityDirect (cw, edges.of.interest, 255)
  redraw (cw)

RCytoscape documentation built on Nov. 17, 2017, 10:52 a.m.