Skip to content

jhrcek/force-layout

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Force directed graph layout in Elm

Implementation of force directed layout algorithm in Elm.

The aim of force directed graph drawing algorithms is to produce aesthetically pleasing layout of graphs by simulating attractive / repulsive forces among nodes of the graph.

See it in action here

Things you can try:

  • Several example graphs
  • Move nodes using drag and drop
  • Tweak layout algorithm parameters using sliders

Note this implementation is still experimental, but I'd like to make this into reusable library soon.

TODOs

  • Add possibility to tweak layout algorithm parameters in UI
  • Add sample graphs
  • Add node drag & drop
  • Implement random graph (tree?) generation
  • Make Physics simulation code more readable
  • linear-algebra should not be needed - implement the primitives in separate module
  • Add parameter explanation hints
  • Make node / edge rendering logic configurable
  • Enable LayoutGraph initialization without randomization command (perhaps just with random gen seed?)

About

Force-directed graph layout algorithm implemented in Elm

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages