layoutSelectionInGridInferAnchor,RCyjs-method {RCyjs} | R Documentation |
layoutSelectionInGridInferAnchor
the top-most, left-most of the selected nodes is the anchor
## S4 method for signature 'RCyjs' layoutSelectionInGridInferAnchor(obj, w, h)
obj |
an RCyjs instance |
w |
numeric, the width of the grid box |
h |
numeric, the height of the grid box |
anchor (the top left) of the grid is the location of the topmost/leftmost node, then arrange all the selected nodes in a box anchored here.
explain what the method returns
if(interactive()){ g <- simpleDemoGraph() rcy <- RCyjs(title="rcyjs demo", graph=g) layout(rcy, "cose") fit(rcy, 100) loadStyleFile(rcy, system.file(package="RCyjs", "extdata", "sampleStyle2.js")); selectNodes(rcy, nodes(g)) layoutSelectionInGrid(rcy, -1000, 10, 100, 400) }