Class GranularityModifier
- java.lang.Object
-
- org.aksw.limes.core.measures.measure.pointsets.benchmarking.AbstractPolygonModifier
-
- org.aksw.limes.core.measures.measure.pointsets.benchmarking.GranularityModifier
-
- All Implemented Interfaces:
IPolygonModifier
public class GranularityModifier extends AbstractPolygonModifier
- Author:
- Axel-C. Ngonga Ngomo (ngonga@informatik.uni-leipzig.de)
-
-
Constructor Summary
Constructors Constructor Description GranularityModifier()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetName()Return name of modifier classPolygonmodify(Polygon p, double threshold)Modifies a polygon by reducing the total amount of points that describe it to threshold * original number of points.-
Methods inherited from class org.aksw.limes.core.measures.measure.pointsets.benchmarking.AbstractPolygonModifier
modifySet
-
-
-
-
Method Detail
-
modify
public Polygon modify(Polygon p, double threshold)
Modifies a polygon by reducing the total amount of points that describe it to threshold * original number of points. Assumes that the threshold is less than 1. If it larger than 1, then it is replaced by 1/threshold. The reduction is carried out randomly by "flipping a coin".- Parameters:
p- Polygonthreshold- of distance- Returns:
- polygon, the modified polygon
-
getName
public String getName()
Description copied from interface:IPolygonModifierReturn name of modifier class- Returns:
- name of modifier, as string
-
-