setPosition,RCyjs-method {RCyjs} | R Documentation

## setPosition

### Description

`setPosition` of nodes by their id

### Usage

    ## S4 method for signature 'RCyjs'
    setPosition(obj, tbl.pos)

### Arguments

`obj` | an RCyjs instance
`tbl.pos` | a data.frame with three columns: id, x, y

### Value

no return value

### See Also

`getPosition`

### Examples

    if(interactive()){
      g <- simpleDemoGraph()
      rcy <- RCyjs(title="getPosition", graph=g)
      layout(rcy, "cose")
      tbl.pos <- getPosition(rcy)
        # shift all the nodes to the right
      tbl.pos$x <- tbl.pos$x + 50
      setPosition(rcy, tbl.pos)
      }

[Package RCyjs version 2.14.0 Index]