package de.ugoe.cs.cpdp.eval; /** *

* Data class to store experiment results *

* * @author Steffen Herbold */ public class ExperimentResult { /** * configuration name of the experiment */ private final String configurationName; /** * name of the target product */ private final String productName; /** * name of the classifier used */ private final String classifier; /** * number of instances of the target product */ int sizeTestData; /** * number of instances of the training data */ int sizeTrainingData; /** * error of the prediction */ double error = Double.NaN; /** * recall of the prediction */ double recall = Double.NaN; /** * precision of the prediction */ double precision = Double.NaN; /** * F1 score of the prediction */ double fscore = Double.NaN; /** * G score of the prediction */ double gscore = Double.NaN; /** * Matthews correlation coefficient of the prediction */ double mcc = Double.NaN; /** * Area under the curve of the prediction */ double auc = Double.NaN; /** * Effort of the prediction */ double aucec = Double.NaN; /** * True positive rate of the prediction */ double tpr = Double.NaN; /** * True negative rate of the prediction */ double tnr = Double.NaN; /** * false positive rate of the prediction */ double fpr = Double.NaN; /** * false negative rate of the prediction */ double fnr = Double.NaN; /** * number of true positives */ double tp = Double.NaN; /** * number of false negatives */ double fn = Double.NaN; /** * number of true negatives */ double tn = Double.NaN; /** * number of false positives */ double fp = Double.NaN; /** *

* Constructor. Creates a new ExperimentResult. *

* * @param configurationName * the configuration name * @param productName * the product name * @param classifier * the classifier name */ public ExperimentResult(String configurationName, String productName, String classifier) { this.configurationName = configurationName; this.productName = productName; this.classifier = classifier; } /** *

* returns the configuration name *

* * @return the configuration name */ public String getConfigurationName() { return configurationName; } /** *

* returns the product name *

* * @return the product name */ public String getProductName() { return productName; } /** *

* returns the classifier name *

* * @return the classifier name */ public String getClassifier() { return classifier; } /** *

* returns the number of instances of the target product *

* * @return number of instances */ public int getSizeTestData() { return sizeTestData; } /** *

* sets the number of instances of the target product *

* * @param sizeTestData * number of instances */ public void setSizeTestData(int sizeTestData) { this.sizeTestData = sizeTestData; } /** *

* returns the number of instances of the training data *

* * @return number of instances */ public int getSizeTrainingData() { return sizeTrainingData; } /** *

* sets the number of instances of the training data *

* * @param sizeTrainingData * number of instances */ public void setSizeTrainingData(int sizeTrainingData) { this.sizeTrainingData = sizeTrainingData; } /** *

* returns the error *

* * @return the error */ public double getError() { return error; } /** *

* sets the error *

* * @param error * the error */ public void setError(double error) { this.error = error; } /** *

* returns the recall *

* * @return the recall */ public double getRecall() { return recall; } /** *

* sets the recall *

* * @param recall * the recall */ public void setRecall(double recall) { this.recall = recall; } /** *

* returns the precision *

* * @return the precision */ public double getPrecision() { return precision; } /** *

* sets the precision *

* * @param precision * the precision */ public void setPrecision(double precision) { this.precision = precision; } /** *

* returns the F1 score *

* * @return the F1 score */ public double getFscore() { return fscore; } /** *

* sets the F1 score *

* * @param fscore * the F1 score */ public void setFscore(double fscore) { this.fscore = fscore; } /** *

* returns the G score *

* * @return the G score */ public double getGscore() { return gscore; } /** *

* sets the G score *

* * @param gscore * the G score */ public void setGscore(double gscore) { this.gscore = gscore; } /** *

* returns the MCC *

* * @return the MCC */ public double getMcc() { return mcc; } /** *

* sets the MCC *

* * @param mcc * the MCC */ public void setMcc(double mcc) { this.mcc = mcc; } /** *

* returns the AUC *

* * @return the AUC */ public double getAuc() { return auc; } /** *

* sets the AUC *

* * @param auc * the AUC */ public void setAuc(double auc) { this.auc = auc; } /** *

* returns the effort as AUCEC *

* * @return the effort */ public double getAucec() { return aucec; } /** *

* sets the effort as AUCEC *

* * @param aucec * the effort */ public void setAucec(double aucec) { this.aucec = aucec; } /** *

* returns the TPR *

* * @return the TPR */ public double getTpr() { return tpr; } /** *

* sets the TPR *

* * @param tpr * the TPR */ public void setTpr(double tpr) { this.tpr = tpr; } /** *

* sets the TNR *

* * @return the TNR */ public double getTnr() { return tnr; } /** *

* sets the TNR *

* * @param tnr * the TNR */ public void setTnr(double tnr) { this.tnr = tnr; } /** *

* returns the FPR *

* * @return the FPR */ public double getFpr() { return fpr; } /** *

* sets the FPR *

* * @param fpr * the FPR */ public void setFpr(double fpr) { this.fpr = fpr; } /** *

* returns the FNR *

* * @return the FNR */ public double getFnr() { return fnr; } /** *

* sets the FNR *

* * @param fnr * the FNR */ public void setFnr(double fnr) { this.fnr = fnr; } /** *

* returns the TPs *

* * @return the TPs */ public double getTp() { return tp; } /** *

* sets the TPs *

* * @param tp * the TPs */ public void setTp(double tp) { this.tp = tp; } /** *

* returns the FNs *

* * @return the FNs */ public double getFn() { return fn; } /** *

* sets the FNs *

* * @param fn */ public void setFn(double fn) { this.fn = fn; } /** *

* returns the TNs *

* * @return the TNs */ public double getTn() { return tn; } /** *

* sets the TNs *

* * @param tn * the TNs */ public void setTn(double tn) { this.tn = tn; } /** *

* returns the FPs *

* * @return the FPs */ public double getFp() { return fp; } /** *

* sets the FPs *

* * @param fp * the FPs */ public void setFp(double fp) { this.fp = fp; } }