|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.myra.datamining.UnitAveragingMode<V>
public abstract class UnitAveragingMode<V extends java.lang.Comparable<V>>
Nested Class Summary | |
---|---|
static class |
UnitAveragingMode.DoubleUnitAveragingMode
Default averaging mode for Double values. |
Constructor Summary | |
---|---|
UnitAveragingMode()
|
Method Summary | |
---|---|
java.lang.String |
average(Unit<?>[] values)
Returns a String which corresponds to the average values
of the specified units. |
int |
compare(Unit<?> u1,
Unit<?> u2)
|
protected int |
compareTo(Unit<V> u1,
Unit<V> u2)
Compares the specified unit instances. |
static UnitAveragingMode<?> |
get(java.lang.Class<?> c)
|
protected abstract java.lang.String |
getAverage(Unit<V>[] values)
Returns a String which corresponds to the average values
of the specified units. |
static void |
register(java.lang.Class<?> c,
UnitAveragingMode<?> mode)
Registers the specified averaging mode. |
static java.lang.String |
stdev(java.util.Collection<? extends java.lang.Number> numbers)
|
static java.lang.String |
stdev(double[] numbers)
Caculates the mean and standard deviation. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public UnitAveragingMode()
Method Detail |
---|
public static void register(java.lang.Class<?> c, UnitAveragingMode<?> mode)
c
- the target unit class name.mode
- the averaging mode instance.public static UnitAveragingMode<?> get(java.lang.Class<?> c)
public static java.lang.String stdev(java.util.Collection<? extends java.lang.Number> numbers)
public static java.lang.String stdev(double[] numbers)
numbers
- the distribution.public java.lang.String average(Unit<?>[] values)
String
which corresponds to the average values
of the specified units.
values
- the array of unit values.
String
which corresponds to the average values
of the specified units.public int compare(Unit<?> u1, Unit<?> u2)
protected abstract java.lang.String getAverage(Unit<V>[] values)
String
which corresponds to the average values
of the specified units.
values
- the array of unit values.
String
which corresponds to the average values
of the specified units.protected int compareTo(Unit<V> u1, Unit<V> u2)
u1
- the first unit.u2
- the second unit.
u1
is less than, equal to, or greater than the
specified u2
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |