Class ComputeErrDegree<T>
java.lang.Object
de.uni_mannheim.informatik.dws.melt.matching_jena_matchers.multisource.clustering.ComputeErrDegree<T>
This class can compute two things:
1) Communities detected by the Louvrain algorithm. 2) Error degree of an edge as computed by Detecting Erroneous Identity Links on the Web Using Network Metrics by Raad J., Beek W., van Harmelen F., Pernelle N., Saïs F. (2018). This class represents a graph of sameas edges. The edges can be added by the addEdge method. After adding some edges, you can call detectCommunities or computeLinkError.
1) Communities detected by the Louvrain algorithm. 2) Error degree of an edge as computed by Detecting Erroneous Identity Links on the Web Using Network Metrics by Raad J., Beek W., van Harmelen F., Pernelle N., Saïs F. (2018). This class represents a graph of sameas edges. The edges can be added by the addEdge method. After adding some edges, you can call detectCommunities or computeLinkError.
-
Field Summary
Modifier and TypeFieldDescriptionprivate int
private int
private static final org.slf4j.Logger
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
void
(package private) void
private Clustering
computeClustering
(int modularityFunction, double resolution, long randomSeed, int nRandomStarts, int nIterations, ModularityAlgorithm algorithm) computeClusterToID
(Clustering clustering) computeElementToCluster
(Clustering clustering) computeIDToCluster
(Map<Integer, List<Integer>> clusterToID) computeLinkError
(int modularityFunction, double resolution, long randomSeed, int nRandomStarts, int nIterations, ModularityAlgorithm algorithm) computeLinkError
(ModularityAlgorithm algorithm) Detect communities in this graph.detectCommunities
(int modularityFunction, double resolution, long randomSeed, int nRandomStarts, int nIterations, ModularityAlgorithm algorithm) Detect communities in this graph.detectCommunities
(ModularityAlgorithm algorithm) Detect communities in this graph.private Network
getNetwork
(int modularityFunction) Based on the uniformDirectedEdges attribute of the class, computes the internal representation (Network).private int
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
elementToID
-
idToElement
-
uniformDirectedEdges
-
currentID
private int currentID -
countUndirectedEdges
private int countUndirectedEdges
-
-
Constructor Details
-
ComputeErrDegree
public ComputeErrDegree()
-
-
Method Details
-
addNodes
-
addEdge
-
addEdge
-
getNodeID
-
detectCommunities
Detect communities in this graph. Default values for the parameters are used.- Returns:
- a map from element to corresponding community number
-
detectCommunities
Detect communities in this graph.- Parameters:
algorithm
- Algorithm for modularity optimization- Returns:
- a map from element to corresponding community number
-
detectCommunities
public Map<T,Integer> detectCommunities(int modularityFunction, double resolution, long randomSeed, int nRandomStarts, int nIterations, ModularityAlgorithm algorithm) Detect communities in this graph.- Parameters:
modularityFunction
- Modularity function (1 = standard; 2 = alternative)resolution
- Use a value of 1.0 for standard modularity-based community detection. Use a value above (below) 1.0 if you want to obtain a larger (smaller) number of communities.randomSeed
- Seed of the random number generatornRandomStarts
- Number of random startsnIterations
- Number of iterations per random startalgorithm
- Algorithm for modularity optimization- Returns:
- a map from element to corresponding community number
-
computeClustering
private Clustering computeClustering(int modularityFunction, double resolution, long randomSeed, int nRandomStarts, int nIterations, ModularityAlgorithm algorithm) -
computeLinkError
-
computeLinkError
-
computeLinkError
-
computeClusterToID
-
computeIDToCluster
-
computeElementToCluster
-
getNetwork
Based on the uniformDirectedEdges attribute of the class, computes the internal representation (Network).- Parameters:
modularityFunction
- the modularity Function- Returns:
- the internal representation (Network)
-