Class ClosenessCentrality<V,E>
java.lang.Object
edu.uci.ics.jung.algorithms.scoring.DistanceCentralityScorer<V,E>
edu.uci.ics.jung.algorithms.scoring.ClosenessCentrality<V,E>
- All Implemented Interfaces:
VertexScorer<V,Double>
Assigns scores to each vertex based on the mean distance to each other vertex.
-
Field Summary
Fields inherited from class DistanceCentralityScorer
averaging, distance, graph, ignore_missing, ignore_self_distances, output -
Constructor Summary
ConstructorsConstructorDescriptionClosenessCentrality(Hypergraph<V, E> graph) Creates an instance which measures distance on the graph without edge weights.ClosenessCentrality(Hypergraph<V, E> graph, com.google.common.base.Function<E, ? extends Number> edge_weights) Creates an instance which measures distance using the specified edge weights.ClosenessCentrality(Hypergraph<V, E> graph, Distance<V> distance) Creates an instance using the specified vertex/vertex distance metric. -
Method Summary
Methods inherited from class DistanceCentralityScorer
getVertexScore
-
Constructor Details
-
ClosenessCentrality
Creates an instance using the specified vertex/vertex distance metric.- Parameters:
graph- the inputdistance- the vertex/vertex distance metric.
-
ClosenessCentrality
public ClosenessCentrality(Hypergraph<V, E> graph, com.google.common.base.Function<E, ? extends Number> edge_weights) Creates an instance which measures distance using the specified edge weights.- Parameters:
graph- the input graphedge_weights- the edge weights to be used to determine vertex/vertex distances
-
ClosenessCentrality
Creates an instance which measures distance on the graph without edge weights.- Parameters:
graph- the graph whose vertices' centrality scores will be calculated
-