Open mbostock opened 1 year ago
Nice! It would be great also to allow using other marks than dot & link? e.g. if you want images, or labels, to follow the dots, and links to be directed (and bent) arrows? The simulation and drag would be unchanged, but the display would be different.
For a long while I've wanted a declarative way to generate d3 force graphs, so I'm really excited to see this get proposed / prototyped.
My desires for declarative d3 force graphs fall into 3 categories:
I'm curious how you see d3 force graphs in plot evolving, and where in this ability progression we might see a cutoff.
Relatedly, I wonder if force graphs (which don't fit the standards regarding x and y that all other marks do) would be treated as a different base level primitive, or whether you could have a marks array with a force graph mark and a bar mark coexisting.
Proof of concept using render transforms:
https://github.com/observablehq/plot/assets/230541/4799d063-20e6-4f2c-b91a-3ccb110f754f
https://observablehq.com/d/200ed525020b8df1
Still to figure out: