layout,RCyjs-method {RCyjs} | R Documentation

## layout

### Description

`layout` apply a layout algorithm to the current grap

### Usage

    ## S4 method for signature 'RCyjs'
    layout(obj, strategy = "random")

### Arguments

`obj` | an RCyjs instance
`strategy` | a character string, one of the supported algorithms

### Value

explain what the method returns

### See Also

`getLayoutStrategies`

### Examples

    if(interactive()){
      g <- createTestGraph(nodeCount=20, edgeCount=20)
      rcy <- RCyjs(title="layouts", graph=g)
      strategies <- getLayoutStrategies(rcy)
      for(strategy in stategies){
         layout(rcy, strategy)
         Sys.sleep(1)
         }
      }

[Package RCyjs version 2.4.0 Index]