Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What needs to be done to achieve this? #697

Closed
devkhan opened this issue Jan 5, 2016 · 5 comments
Closed

What needs to be done to achieve this? #697

devkhan opened this issue Jan 5, 2016 · 5 comments
Labels

Comments

@devkhan
Copy link

devkhan commented Jan 5, 2016

Can something like this be implemented using sigma.js.
I know draggable nodes and force directed layout can be done. But my graph has >200 nodes, so ForceAtlas2 doesn't stabilize even for a long period of time. So, I found this and this was in d3.js.

Can anyone tell me if it is possible in sigma.js, if yes, what do I need to do?

I don't want how to do this but if anyone can tell what steps need to taken, do I need to implement a different layout algorithm in a plugin or what exactly should I do, it would be really helpful?

@tsouk
Copy link

tsouk commented Feb 23, 2016

Good question.
I am also trying to get ForceAtlas2 to work with incremental additions (random x,y) of nodes. It seems to be disregarding the ones that were created after the initial startForceAtlas2().

@Yomguithereal
Copy link
Collaborator

@tsouk, you need to kill forceAtlas and restart it every time you add drop something from the graph. The reason why you must do this is that the layout algorithm is very low-level for performance reasons and works on a FloatArray that needs to be reconstructed if the graph's structure changes. In the future, we'll work this out for you through events.

@tsouk
Copy link

tsouk commented Feb 23, 2016

Thank you for your quick reply @Yomguithereal!
Same goes for adding nodes, adding/removing edges?

Event listening for changes in the layout would be amazing.

Update: Yup, works. I might try the click-drag-add that @devkhan is looking for then

@Yomguithereal
Copy link
Collaborator

Adding/dropping nodes/edges are the case where you need to reset the layout. Other cases should be safe (apart if you need to hide some nodes or change their position in spite of the layout).

@stale
Copy link

stale bot commented Oct 9, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Oct 9, 2021
@stale stale bot closed this as completed Oct 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants