Package edu.uci.ics.jung.algorithms.scoring

Examples of edu.uci.ics.jung.algorithms.scoring.DistanceCentralityScorer


                graph.addEdge(coluns[2] + " (" + i + ")", coluns[1], coluns[0]);
            }
        }

        BetweennessCentrality<String, String> btw = new BetweennessCentrality<>(graph);
        DistanceCentralityScorer<String, String> dst = new DistanceCentralityScorer(graph, false);
        ClosenessCentrality<String, String> cls = new ClosenessCentrality<>(graph);
        DegreeScorer<String> dgr = new DegreeScorer<>(graph);
        List<AuxUserMetrics> userMetrics = new ArrayList<>();

        for (String vertex : graph.getVertices()) {
            userMetrics.add(new AuxUserMetrics(vertex,
                    btw.getVertexScore(vertex), // betweeness
                    dst.getVertexScore(vertex), // distance
                    dgr.getVertexScore(vertex), // degree
                    cls.getVertexScore(vertex))); // closeness
        }

        addToEntityMetricNodeList(userMetrics);
View Full Code Here

TOP

Related Classes of edu.uci.ics.jung.algorithms.scoring.DistanceCentralityScorer

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.