public class PropertyRanker extends BaseEntryRanker
Usage: <property> <ranker> [<ranker options...>]
property: Name of property used for ranking
ranker: Name of BaseEntryRanker to use
ranker options...: Options for the ranker
Modifier and Type | Field and Description |
---|---|
protected int |
PropertyIndex
Index of property used for ranking
|
protected java.lang.String |
PropertyName
Name of property used for ranking
|
Constructor and Description |
---|
PropertyRanker() |
Modifier and Type | Method and Description |
---|---|
double |
objectiveFunction(BaseEntry entry)
Some kind of objective function that returns a double when given an entry.
|
java.lang.String |
printUsage()
Print out required format for options.
|
void |
setMaximizeFunction(boolean toMaximize)
Set whether this entry ranker will maximize objective function
|
void |
setOptions(java.util.List<java.lang.Object> Options)
Set any options for this object.
|
void |
setPropertyName(java.lang.String name)
Set the name of property used for ranking
|
void |
setSubRanker(BaseEntryRanker subRanker)
Set the ranker employed by this class.
|
void |
setUseMeasured(boolean useMeasured)
Set whether to used measured (or predicted) class values
|
void |
train(Dataset data)
Train ranker.
|
clone, isMaximizing, isUsingMeasured, rankEntries, rankEntries, rankEntries, runObjectiveFunction, sortByRanking
protected java.lang.String PropertyName
protected int PropertyIndex
public void setOptions(java.util.List<java.lang.Object> Options) throws java.lang.Exception
Options
Options
- Array of options as Objects - can be null
java.lang.Exception
- if problem with inputspublic java.lang.String printUsage()
Options
public void setSubRanker(BaseEntryRanker subRanker)
subRanker
- Ranker used to rank by property valuespublic void setPropertyName(java.lang.String name)
name
- Name of propertypublic void setUseMeasured(boolean useMeasured)
BaseEntryRanker
setUseMeasured
in class BaseEntryRanker
useMeasured
- Desired optionpublic void setMaximizeFunction(boolean toMaximize)
BaseEntryRanker
setMaximizeFunction
in class BaseEntryRanker
toMaximize
- Whether to maximize functionpublic void train(Dataset data)
BaseEntryRanker
train
in class BaseEntryRanker
data
- Data to use as training setpublic double objectiveFunction(BaseEntry entry)
BaseEntryRanker
NOTE: This function needs to support using either the measured or predicted class depending on the settings
objectiveFunction
in class BaseEntryRanker
entry
- Entry to be analyzed