|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.udo.cs.yale.operator.AbstractIOObject
edu.udo.cs.yale.operator.ResultObjectAdapter
edu.udo.cs.yale.tools.math.Averagable
edu.udo.cs.yale.operator.performance.PerformanceCriterion
edu.udo.cs.yale.operator.performance.MeasuredPerformance
edu.udo.cs.yale.operator.performance.RootRelativeSquaredError
public class RootRelativeSquaredError
Relative squared error is the total squared error made relative to what the error would have been if the prediction had been the average of the absolute value. As done with the root mean-squared error, the square root of the relative squared error is taken to give it the same dimensions as the predicted values themselves. Also, just like root mean-squared error, this exaggerates the cases in which the prediction error was significantly greater than the mean error.
| Field Summary | |
|---|---|
private double |
deviationSum
|
private int |
exampleCounter
|
private Attribute |
labelAttribute
|
private Attribute |
predictedAttribute
|
private double |
relativeSum
|
private double |
trueLabelSum
|
| Constructor Summary | |
|---|---|
RootRelativeSquaredError()
|
|
| Method Summary | |
|---|---|
void |
buildSingleAverage(Averagable performance)
This method should build the average of this and another averagables of the same type. |
protected void |
cloneAveragable(Averagable newPC)
Must be implemented by subclasses such that it copies all values of other to this. |
void |
countExample(Example example)
Calculates the error for the current example. |
java.lang.String |
getDescription()
Returns a description of the performance criterion. |
int |
getExampleCount()
Returns the number of data points which was used to determine the criterion value. |
double |
getFitness()
Returns the fitness depending on the value. |
double |
getMikroAverage()
Returns the (current) value of the averagable (the average itself). |
double |
getMikroVariance()
Returns the variance of the averagable. |
java.lang.String |
getName()
Returns the name of this averagable. |
void |
readCriterionData(java.io.BufferedReader in)
Reads the performance data from the given reader. |
void |
startCounting(ExampleSet exampleSet)
Initialises the criterion. |
void |
writeCriterionData(java.io.PrintWriter out)
Writes the performance criterion into the given writer. |
| Methods inherited from class edu.udo.cs.yale.operator.performance.PerformanceCriterion |
|---|
compareTo, getMaxFitness, readPerformanceCriterion, writePerformanceCriterion |
| Methods inherited from class edu.udo.cs.yale.tools.math.Averagable |
|---|
buildAverage, clone, formatDeviation, formatPercent, formatValue, getAverage, getMakroAverage, getMakroStandardDeviation, getMakroVariance, getMikroStandardDeviation, getStandardDeviation, getVariance, toHTML, toString |
| Methods inherited from class edu.udo.cs.yale.operator.ResultObjectAdapter |
|---|
addAction, getActions, getVisualisationComponent, toHTML, toResultString |
| Methods inherited from class edu.udo.cs.yale.operator.AbstractIOObject |
|---|
copy, read, read, read, write, write |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface edu.udo.cs.yale.operator.IOObject |
|---|
copy, write, write |
| Field Detail |
|---|
private Attribute predictedAttribute
private Attribute labelAttribute
private double deviationSum
private double relativeSum
private double trueLabelSum
private int exampleCounter
| Constructor Detail |
|---|
public RootRelativeSquaredError()
| Method Detail |
|---|
public void writeCriterionData(java.io.PrintWriter out)
throws java.io.IOException
PerformanceCriterion
writeCriterionData in class PerformanceCriterionjava.io.IOException
public void readCriterionData(java.io.BufferedReader in)
throws java.io.IOException
PerformanceCriterion
readCriterionData in class PerformanceCriterionjava.io.IOExceptionpublic java.lang.String getName()
Averagable
getName in interface ResultObjectgetName in class Averagablepublic java.lang.String getDescription()
MeasuredPerformance
getDescription in class MeasuredPerformancepublic int getExampleCount()
PerformanceCriterion
getExampleCount in class PerformanceCriterion
public void startCounting(ExampleSet exampleSet)
throws OperatorException
MeasuredPerformance
startCounting in class MeasuredPerformanceOperatorExceptionpublic void countExample(Example example)
countExample in class MeasuredPerformancepublic double getMikroAverage()
Averagable
getMikroAverage in class Averagablepublic double getMikroVariance()
Averagable
getMikroVariance in class Averagablepublic double getFitness()
PerformanceCriterion
getFitness in class PerformanceCriterionprotected void cloneAveragable(Averagable newPC)
Averagableother to this. When this method is called,
it is guaranteed, that other is a subclass of the class of
the object it is called on.
cloneAveragable in class Averagablepublic void buildSingleAverage(Averagable performance)
AveragableSimpleCriterion for a simple
implementation example.
buildSingleAverage in class Averagable
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||