|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.ObjectJavaMI.Entropy
public abstract class Entropy
Implements common discrete Shannon Entropy functions. Provides: univariate entropy H(X), conditional entropy H(X|Y), joint entropy H(X,Y). Defaults to log_2, and so the entropy is calculated in bits.
| Field Summary | |
|---|---|
static double |
LOG_BASE
|
| Method Summary | |
|---|---|
static double |
calculateConditionalEntropy(double[] dataVector,
double[] conditionVector)
Calculates the conditional entropy H(X|Y) from two vectors. |
static double |
calculateEntropy(double[] dataVector)
Calculates the univariate entropy H(X) from a vector. |
static double |
calculateJointEntropy(double[] firstVector,
double[] secondVector)
Calculates the joint entropy H(X,Y) from two vectors. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static double LOG_BASE
| Method Detail |
|---|
public static double calculateEntropy(double[] dataVector)
dataVector - Input vector (X). It is discretised to the floor of each value before calculation.
public static double calculateConditionalEntropy(double[] dataVector,
double[] conditionVector)
dataVector - Input vector (X). It is discretised to the floor of each value before calculation.conditionVector - Input vector (Y). It is discretised to the floor of each value before calculation.
public static double calculateJointEntropy(double[] firstVector,
double[] secondVector)
firstVector - Input vector. It is discretised to the floor of each value before calculation.secondVector - Input vector. It is discretised to the floor of each value before calculation.
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||