Main Page | Class Hierarchy | Class List | Class Members

kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix Class Reference

Inheritance diagram for kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix:

kddml.Core.DataMining.CategoryMatrix kddml.Core.DataMining.ClassificationTrees.ConfusionMatrixManager kddml.Core.DataMining.CategoryMatrixManager kddml.Core.DataMining.CategoryMatrixManager List of all members.

Public Member Functions

 ConfusionMatrix (String[] categories, boolean training_set)
int getNumberOfPredictions ()
String[] getCategories ()
double getPercentageAccuracy ()
int getIncorrectlyPredictions ()
double getPercentageError ()
void setValue (String actual_value, String predicted_value, double predictions) throws MiningModelException
double getValue (String actual_value, String predicted_value) throws MiningModelException
String toString ()

Protected Member Functions

 ConfusionMatrix (Element confusion_matrix)

Detailed Description

A ConfusionMatrix specifies the statistics of the correct predictions and mispredictions. The rows represent the predicted classes whereas the columns indicate the correct class values. The value at entry (j, k) is the number of predictions for class j when k is the correct prediction.
On the rows we assume the actual values. On the columns we assume the predicted values.

Title: KDDML

Description: Knowledge Discovery in Database Environment

Copyright: Copyright (c) 2003-2005

Company: Universita' di Pisa - Dipartimento di Informatica

Author:
Andrea Romei (romei@di.unipi.it)
Version:
2.0.16


Constructor & Destructor Documentation

kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix.ConfusionMatrix String[]  categories,
boolean  training_set
 

Constructor given the list of fields related to the target attribute.

Parameters:
categories String[] the categories of target attribute (e.g. "sunny", "overcast", "rainy")
training_set boolean if true, the matrix is a training confusion matrix. Otherwise, the matrix is a test confusion matrix.

kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix.ConfusionMatrix Element  confusion_matrix  )  [protected]
 

Proprietary constructor given the PMML element.

Parameters:
confusion_matrix Element


Member Function Documentation

int kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix.getNumberOfPredictions  ) 
 

Returns the total number of predications.

Returns:
int

Implements kddml.Core.DataMining.ClassificationTrees.ConfusionMatrixManager.

String [] kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix.getCategories  ) 
 

Returns the categories related to the target attribute.

Returns:
String[]

Reimplemented from kddml.Core.DataMining.CategoryMatrix.

double kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix.getPercentageAccuracy  ) 
 

Returns the ratio of the sum of the diagonal entries to the sum of all entries. The output value is a number between 0 and 1.

Returns:
double

Implements kddml.Core.DataMining.ClassificationTrees.ConfusionMatrixManager.

int kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix.getIncorrectlyPredictions  ) 
 

Returns the total number of the incorrectly predictions related to this confusion matrix.

Returns:
int

Implements kddml.Core.DataMining.ClassificationTrees.ConfusionMatrixManager.

double kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix.getPercentageError  ) 
 

Returns the sum of the non-diagonal sums where the actual value does not equal to predicted value, divided by the sum of all cells. The output value is a number between 0 and 1.

Returns:
double

Implements kddml.Core.DataMining.ClassificationTrees.ConfusionMatrixManager.

void kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix.setValue String  actual_value,
String  predicted_value,
double  predictions
throws MiningModelException
 

Sets the number of prediction when the actual prediction is actual_value and the predicted value is predicted_value.

Parameters:
actual_value String the actual category value for the target attribute.
predicted_value String the predicated category value for the target attribute.
predictions double the value to set in the matrix.
Exceptions:
MiningModelException 

Reimplemented from kddml.Core.DataMining.CategoryMatrix.

double kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix.getValue String  actual_value,
String  predicted_value
throws MiningModelException
 

Returns the number of predictions for the given class when the actual prediction is actual_value and the predicted value is predicated_value.

Parameters:
actual_value String
predicted_value String
Exceptions:
MiningModelException 
Returns:
double

Reimplemented from kddml.Core.DataMining.CategoryMatrix.

String kddml.Core.DataMining.ClassificationTrees.ConfusionMatrix.toString  ) 
 

Returns a representation of this object as string.

Returns:
String

Reimplemented from kddml.Core.DataMining.CategoryMatrix.


Generated on Thu Feb 23 13:04:39 2006 for kddml by  doxygen 1.4.3