|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectde.jstacs.parameters.Parameter
de.jstacs.parameters.CollectionParameter
de.jstacs.parameters.MultiSelectionCollectionParameter
de.jstacs.classifier.MeasureParameters
public final class MeasureParameters
This class holds the parameters for evaluate-methods of a classifier.
AbstractClassifier.evaluate(MeasureParameters, boolean, de.jstacs.data.Sample...),
AbstractClassifier.evaluateAll(MeasureParameters, boolean, de.jstacs.data.Sample...)| Nested Class Summary | |
|---|---|
static class |
MeasureParameters.Measure
This Enum defines all measures that are currently implemented in Jstacs. |
| Nested classes/interfaces inherited from class de.jstacs.parameters.CollectionParameter |
|---|
CollectionParameter.InconsistentCollectionException |
| Field Summary |
|---|
| Fields inherited from class de.jstacs.parameters.CollectionParameter |
|---|
errorMessage, parameters, userSelected |
| Fields inherited from class de.jstacs.parameters.Parameter |
|---|
neededReference, neededReferenceId, parent |
| Constructor Summary | |
|---|---|
MeasureParameters(boolean evaluateAll)
This constructor creates a new empty instance of MeasureParameters. |
|
MeasureParameters(boolean evaluateAll,
double sp,
double snForFPR,
double snForPPV)
This constructor creates a new instance of MeasureParameters. |
|
MeasureParameters(boolean evaluateAll,
double sp,
double snForFPR,
double snForPPV,
double minSpec,
double maxSpec,
int steps,
RangeParameter.Scale scale)
|
|
MeasureParameters(StringBuffer representation)
Re-creates a MeasureParameters instance from its XML-representation as returned by MultiSelectionCollectionParameter.toXML(). |
|
| Method Summary | |
|---|---|
void |
deselectAll()
De-selects all measures, i.e. calls setSelected(Measure, false)} for all MeasureParameters.Measures. |
LinkedList<Result> |
getAnnotation()
Returns the selected parameters and their values as a list of results. |
boolean |
isSelected(MeasureParameters.Measure sel)
Returns true if the option sel is selected. |
void |
setSelected(MeasureParameters.Measure sel,
boolean b)
Selects or de-selects the option sel depending on b. |
| Methods inherited from class de.jstacs.parameters.MultiSelectionCollectionParameter |
|---|
checkValue, clone, fromXML, getNumberOfNexts, getNumberOfValues, getSelected, getValue, getValueFor, getValueFor, getValues, hasDefaultOrIsSet, isAtomic, isRanged, isSelected, isSelected, isSet, next, reset, resetToFirst, setDefault, setSelected, setSelected, setValue, simplify, toXML, valuesToString |
| Methods inherited from class de.jstacs.parameters.CollectionParameter |
|---|
appendCollection, createParameterSet, equals, extractCollection, getComment, getDatatype, getDefault, getErrorMessage, getName, getParametersInCollection, getRangedInstance, hasDefault, isRangeable, isRequired, isUserSelected, setRangeable |
| Methods inherited from class de.jstacs.parameters.Parameter |
|---|
getId, getNeededReference, getNeededReferenceId, getParent, setNeededReference, setParent |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MeasureParameters(boolean evaluateAll)
throws ParameterException
evaluateAll - if true the instance contains the parameters for the evaluateAll-method, otherwise it
only contains the parameters for the evaluate-method
ParameterException
public MeasureParameters(boolean evaluateAll,
double sp,
double snForFPR,
double snForPPV)
throws ParameterException
evaluateAll - if true the instance contains the parameters for the evaluateAll-method, otherwise it
only contains the parameters for the evaluate-methodsp - the (fixed) specificitysnForFPR - the (fixed) sensitivity for the FPRsnForPPV - the (fixed) sensitivity for the PPV
ParameterException
public MeasureParameters(boolean evaluateAll,
double sp,
double snForFPR,
double snForPPV,
double minSpec,
double maxSpec,
int steps,
RangeParameter.Scale scale)
throws ParameterException
evaluateAll - if true the instance contains the parameters for the evaluateAll-method, otherwise it
only contains the parameters for the evaluate-methodsp - the (fixed) specificitysnForFPR - the (fixed) sensitivity for the FPRsnForPPV - the (fixed) sensitivity for the PPVminSpec - the minimal specificitymaxSpec - the maximal specificitysteps - the number of stepsscale - see RangerParameter
ParameterExceptionRangeParameter.Scale
public MeasureParameters(StringBuffer representation)
throws NonParsableException
MeasureParameters instance from its XML-representation as returned by MultiSelectionCollectionParameter.toXML().
representation - the XML-representation
NonParsableException - is thrown if the XML-code could not be parsed| Method Detail |
|---|
public void setSelected(MeasureParameters.Measure sel,
boolean b)
sel depending on b.
sel - the optionb - the new selectionpublic boolean isSelected(MeasureParameters.Measure sel)
sel is selected.
sel - the option
sel is selectedpublic void deselectAll()
setSelected(Measure, false)} for all MeasureParameters.Measures.
public LinkedList<Result> getAnnotation()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||