Edge Coloring
Posted: 08 Jun 2017 12:22
Hi,
Can anyone tell me how to color the edges based upon its weight using gephi toolkit jar 0.9 ? I tried it like this..
Column col=graphModel.getEdgeTable().getColumn("weight");
Function centralityRanking2 = appearanceModel.getEdgeFunction(graph,col, RankingElementColorTransformer.class);
System.out.println(centralityRanking2);
System.out.println("centralityRanking2.."+centralityRanking2);
Partition color = centralityRanking2.getTransformer();
Palette palette = PaletteManager.getInstance().generatePalette(color.size());
color.setColors(palette.getColors());
appearanceController.transform(centralityRanking2);
But this is not working.. Can someone tell me whats wrong in this?
Can anyone tell me how to color the edges based upon its weight using gephi toolkit jar 0.9 ? I tried it like this..
Column col=graphModel.getEdgeTable().getColumn("weight");
Function centralityRanking2 = appearanceModel.getEdgeFunction(graph,col, RankingElementColorTransformer.class);
System.out.println(centralityRanking2);
System.out.println("centralityRanking2.."+centralityRanking2);
Partition color = centralityRanking2.getTransformer();
Palette palette = PaletteManager.getInstance().generatePalette(color.size());
color.setColors(palette.getColors());
appearanceController.transform(centralityRanking2);
But this is not working.. Can someone tell me whats wrong in this?