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
Network graph : how to make a sticky node #11464
Comments
Hi @Hokseed Thanks for sharing the idea! What you actually need is a treegraph, not a networkgraph - please vote for this feature on our UserVoice or consider using Organization chart. While it's possible to draw tree-like structure in networkgraph, by the definition of the algorithm used in networkgraph makes nodes behaving like particles. For example in tree structure, you expect root to be render on top of the graph, while in network graph nodes will be rendered around the root. What you can do is to set fixed position for a particular node (temporary - until user drag&drop this node), but it's not part of the official API, take a look: https://jsfiddle.net/BlackLabel/kzwhna2q/ |
Just what I needed ! thank you @pawelfus |
Hello, Im reopening this because when I have a very big network graph, setting sticky only one node is useless. What is the best way to set sticky the entire graph once the graph is completely loaded and take all the space in the area ? (having 200 nodes always moving is annoying and not good for the perfs) (and I do need a network graph to do this, the design is perfect for what i want) |
Hi @Hokseed It might be that the series type you are trying to use is not the best for the data you have or the chart you want to get. P.S. |
Ty for your answer @KacperMadej I understand your point and finally I just want to find a way to keep my network graph at the center of my dialogbox... Because sometimes all my nodes go to a side and that's not very nice. I tried in first to make one node sticky and that's now better but still not perfect. |
Hi @Hokseed You can use other options from
Regarding this:
In general, when using networkgraph you need to tinker options a bit, there's no perfect set of default options that will work for all datasets :) |
Closed due to inactivity. |
Hello,
Im trying to make a beautiful network graph like the one from the demo (https://jsfiddle.net/gh/get/library/pure/highcharts/highcharts/tree/master/samples/highcharts/demo/network-graph) but mine had a lot of nodes and they are always in movment.
The chart parameters are the same as the one from the demo.
The thing is that I want to keep the big nodes (I put them big because they are the ancestors of my family tree) on the center. Is there a possibility to make a node fixed / sticky ?
I already tried to disable the simulation (all nodes appears on a side), or with the mass attribute.
Thanks in advance
The text was updated successfully, but these errors were encountered: