T
- type of variable being compared.public class WeightedDegree<T extends Var> extends Object implements ComparatorVariable<T>
Constructor and Description |
---|
WeightedDegree(Store store) |
Modifier and Type | Method and Description |
---|---|
int |
compare(double left,
T var)
It compares the baseline metric to the variable metric.
|
int |
compare(T leftVar,
T rightVar)
It compares the metric of the left variable against the right one.
|
double |
metric(T var)
It returns the metric of the variable given according to the comparator.
|
public WeightedDegree(Store store)
public int compare(double left, T var)
ComparatorVariable
compare
in interface ComparatorVariable<T extends Var>
left
- the baseline for comparison.var
- variable which is compared to baseline.public int compare(T leftVar, T rightVar)
ComparatorVariable
compare
in interface ComparatorVariable<T extends Var>
leftVar
- left variablerightVar
- right variablepublic double metric(T var)
ComparatorVariable
metric
in interface ComparatorVariable<T extends Var>
var
- variable for which metric is computed.Copyright © 2022. All rights reserved.