Class ErrorEstimatePruning
- java.lang.Object
-
- org.aksw.limes.core.ml.algorithm.dragon.Pruning.PruningFunctionDTL
-
- org.aksw.limes.core.ml.algorithm.dragon.Pruning.ErrorEstimatePruning
-
public class ErrorEstimatePruning extends PruningFunctionDTL
-
-
Field Summary
Fields Modifier and Type Field Description static doubledefaultConfidence
-
Constructor Summary
Constructors Constructor Description ErrorEstimatePruning()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static doubleerrorRate(double f, double N, double z)Calculates the pessimistic error rate e using the formula (f + (z^2)/2N + z * sqrt(f/N - f^2/N + z^2/(4N^2)))/1 + z^2/Nstatic voidmain(String[] args)booleanpruneChild(DecisionTree node, AMapping parent)DecisionTreepruneChildNodesIfNecessary(DecisionTree node)Decides if all the child nodes or one of them have to be pruned The nodes have to have the appropriate mappings in the classifiers The child nodes of this node are leaves
-
-
-
Method Detail
-
errorRate
public static double errorRate(double f, double N, double z)Calculates the pessimistic error rate e using the formula (f + (z^2)/2N + z * sqrt(f/N - f^2/N + z^2/(4N^2)))/1 + z^2/N- Parameters:
f- observed error rate E/N, with N number of instances where E are errorsN- number of instancesz- confidence limit- Returns:
- error
-
main
public static void main(String[] args)
-
pruneChildNodesIfNecessary
public DecisionTree pruneChildNodesIfNecessary(DecisionTree node)
Description copied from class:PruningFunctionDTLDecides if all the child nodes or one of them have to be pruned The nodes have to have the appropriate mappings in the classifiers The child nodes of this node are leaves- Specified by:
pruneChildNodesIfNecessaryin classPruningFunctionDTL- Returns:
- node
-
pruneChild
public boolean pruneChild(DecisionTree node, AMapping parent)
-
-