C# Class numl.Math.Information.Impurity

An impurity.
Afficher le fichier Open project: sethjuarez/numl

Méthodes publiques

Méthode Description
Calculate ( Vector x ) : double

Calculates impurity measure of x.

Conditional ( Vector y, Vector x ) : double

Calculates conditional impurity of y | x R(Y|X) is the average of H(Y|X = x) over all possible values X may take.

Gain ( Vector y, Vector x ) : double

Calculates information gain of y | x.

RelativeGain ( Vector y, Vector x ) : double

Calculates relative information gain of y | x.

SegmentedConditional ( Vector y, Vector x, IEnumerable ranges ) : double

Calculates segmented conditional impurity of y | x When stipulating ranges (r), X is broken up into |r| many segments therefore P(X=x_r) becomes a range probability rather than a fixed probability. In essence the average over H(Y|X = x) becomes SUM_s [ p_r * H(Y|X = x_r) ]. The values that were used to do the split are stored in the Splits member.

SegmentedConditional ( Vector y, Vector x, int segments ) : double

Calculates segmented conditional impurity of y | x When stipulating segments (s), X is broken up into s many segments therefore P(X=x_s) becomes a range probability rather than a fixed probability. In essence the average over H(Y|X = x) becomes SUM_s [ p_s * H(Y|X = x_s) ]. The values that were used to do the split are stored in the Splits member.

SegmentedGain ( Vector y, Vector x, IEnumerable ranges ) : double

Segmented gain.

SegmentedGain ( Vector y, Vector x, int segments ) : double

Segmented gain.

SegmentedRelativeGain ( Vector y, Vector x, IEnumerable ranges ) : double

Calculates relative information gain of y | x with under specified ranges.

SegmentedRelativeGain ( Vector y, Vector x, int segments ) : double

Calculates relative information gain of y | x with a specified number of segments.

Method Details

Calculate() public abstract méthode

Calculates impurity measure of x.
public abstract Calculate ( Vector x ) : double
x numl.Math.LinearAlgebra.Vector The list in question.
Résultat double

Conditional() public méthode

Calculates conditional impurity of y | x R(Y|X) is the average of H(Y|X = x) over all possible values X may take.
Thrown when the requested operation is invalid.
public Conditional ( Vector y, Vector x ) : double
y numl.Math.LinearAlgebra.Vector Target impurity.
x numl.Math.LinearAlgebra.Vector Conditioned impurity.
Résultat double

Gain() public méthode

Calculates information gain of y | x.
public Gain ( Vector y, Vector x ) : double
y numl.Math.LinearAlgebra.Vector Target impurity.
x numl.Math.LinearAlgebra.Vector Conditioned impurity.
Résultat double

RelativeGain() public méthode

Calculates relative information gain of y | x.
public RelativeGain ( Vector y, Vector x ) : double
y numl.Math.LinearAlgebra.Vector Target impurity.
x numl.Math.LinearAlgebra.Vector Conditioned impurity.
Résultat double

SegmentedConditional() public méthode

Calculates segmented conditional impurity of y | x When stipulating ranges (r), X is broken up into |r| many segments therefore P(X=x_r) becomes a range probability rather than a fixed probability. In essence the average over H(Y|X = x) becomes SUM_s [ p_r * H(Y|X = x_r) ]. The values that were used to do the split are stored in the Splits member.
Thrown when the requested operation is invalid.
public SegmentedConditional ( Vector y, Vector x, IEnumerable ranges ) : double
y numl.Math.LinearAlgebra.Vector Target impurity.
x numl.Math.LinearAlgebra.Vector Conditioned impurity.
ranges IEnumerable Number of segments over x to condition upon.
Résultat double

SegmentedConditional() public méthode

Calculates segmented conditional impurity of y | x When stipulating segments (s), X is broken up into s many segments therefore P(X=x_s) becomes a range probability rather than a fixed probability. In essence the average over H(Y|X = x) becomes SUM_s [ p_s * H(Y|X = x_s) ]. The values that were used to do the split are stored in the Splits member.
Thrown when the requested operation is invalid.
public SegmentedConditional ( Vector y, Vector x, int segments ) : double
y numl.Math.LinearAlgebra.Vector Target impurity.
x numl.Math.LinearAlgebra.Vector Conditioned impurity.
segments int Number of segments over x to condition upon.
Résultat double

SegmentedGain() public méthode

Segmented gain.
public SegmentedGain ( Vector y, Vector x, IEnumerable ranges ) : double
y numl.Math.LinearAlgebra.Vector Target impurity.
x numl.Math.LinearAlgebra.Vector The list in question.
ranges IEnumerable Number of segments over x to condition upon.
Résultat double

SegmentedGain() public méthode

Segmented gain.
public SegmentedGain ( Vector y, Vector x, int segments ) : double
y numl.Math.LinearAlgebra.Vector Target impurity.
x numl.Math.LinearAlgebra.Vector The list in question.
segments int Number of segments over x to condition upon.
Résultat double

SegmentedRelativeGain() public méthode

Calculates relative information gain of y | x with under specified ranges.
public SegmentedRelativeGain ( Vector y, Vector x, IEnumerable ranges ) : double
y numl.Math.LinearAlgebra.Vector Target impurity.
x numl.Math.LinearAlgebra.Vector Conditioned impurity.
ranges IEnumerable Range breakdown.
Résultat double

SegmentedRelativeGain() public méthode

Calculates relative information gain of y | x with a specified number of segments.
public SegmentedRelativeGain ( Vector y, Vector x, int segments ) : double
y numl.Math.LinearAlgebra.Vector Target impurity.
x numl.Math.LinearAlgebra.Vector Conditioned impurity.
segments int Number of segments.
Résultat double