final PVArcLayout arc = vis.add(PV.Layout.Arc())
.nodes(new NovelCharacterNodeAdapter(), nodes).links(links)
.sort(new Comparator<PVNode>() {
public int compare(PVNode a, PVNode b) {
NovelCharacter ac = a.object();
NovelCharacter bc = b.object();
return ac.getGroup() == bc.getGroup() ? b.linkDegree()
- a.linkDegree() : bc.getGroup()
- ac.getGroup();
}
});
final PVColor arcColor = PV.color("rgba(0,0,0,.2)");