Closed micw42 closed 3 years ago
Hi @micw42 good question! I think you're looking for the code in this example: https://github.com/QuantStack/ipycytoscape/blob/master/examples/Concentric%20example.ipynb
The important step is: cytoscapeobj.set_layout(name='concentric')
Hope that works for you!
Hi @ianhi Thank you for answering my question! Sorry I wasn't being very clear before. I've already donecytoscapeobj.set_layout(name='concentric')
I was wondering if there were a way to control which concentric layer a node ends up in? For example, here is the graph I made:
Would it be possible to make the red node on the left be in the center? Cytoscape.js allows you to set a function that determines which layer a node is in, so I wonder if this is also possible in ipycytoscape? Thank you so much for your help; I really appreciate it :)
Hey @micw42, thanks for opening the issue. I think the reason why you can't do this is the same as: https://github.com/QuantStack/ipycytoscape/issues/238? What do you think? If it is, we can close this issue and keep the discussion centralized in there. For now we don't have a fix! But feel free to add your thoughts and questions there. I can't work on it at the moment but would gladly review a PR if you wanna try it! :) Cheers.
Hey @marimeireles Yeah, I think it's the same; sorry I didn't see it earlier! Thank you :)
No probs! :)
In the concentric layout of cytoscape.js, it is possible to put a node in a certain "layer" of the circle through the
concentric
variable of the layout:Here is the cytoscape.js documentation about this
Is there a similar function to this in ipycytoscape? Thank you so much!