Skip to content

Instantly share code, notes, and snippets.

@aaronpk aaronpk/clusters.rb
Last active Aug 29, 2015

Embed
What would you like to do?
links = [
{:a => :z},
{:b => :z},
{:c => :z},
{:d => :y},
{:e => :x},
{:e => :w},
{:e => :v},
{:f => :u},
{:f => :t},
{:g => :t}
]
expected_clusters = [
{:sources => [:a,:b,:c], :targets => [:z], :text => "a, b and c linked to z"},
{:sources => [:d], :targets => [:y], :text => "d linked to y"},
{:sources => [:e], :targets => [:x,:w,:v], :text => "e linked to x, w, and v"},
{:sources => [:f,:g], :targets => [:u,:t], :text => "f and g linked to u and t"}
]
@aaronpk

This comment has been minimized.

Copy link
Owner Author

aaronpk commented Jul 26, 2015

digraph

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.