A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://accord-framework.net/docs/html/T_Accord_Statistics_Analysis_LinearDiscriminantAnalysis.htm below:

LinearDiscriminantAnalysis Class

Linear Discriminant Analysis (LDA).

Inheritance Hierarchy Namespace:  Accord.Statistics.Analysis
Assembly:

Accord.Statistics (in Accord.Statistics.dll) Version: 3.8.0

Syntax
[SerializableAttribute]
public class LinearDiscriminantAnalysis : BaseDiscriminantAnalysis, 
	IDiscriminantAnalysis, IMultivariateAnalysis, IAnalysis, IProjectionAnalysis, ISupervisedLearning<LinearDiscriminantAnalysisPipeline, double[], int>
<SerializableAttribute>
Public Class LinearDiscriminantAnalysis
	Inherits BaseDiscriminantAnalysis
	Implements IDiscriminantAnalysis, IMultivariateAnalysis, IAnalysis, IProjectionAnalysis, 
	ISupervisedLearning(Of LinearDiscriminantAnalysisPipeline, Double(), Integer)
Request Example View Source

The LinearDiscriminantAnalysis type exposes the following members.

Constructors Properties Methods   Name Description Classify(Double) Obsolete.

Transform Classifies a new instance into one of the available classes.

(Overrides BaseDiscriminantAnalysisClassify(Double).) Classify(Double) Obsolete.

Classifies new instances into one of the available classes.

(Overrides BaseDiscriminantAnalysisClassify(Double).) Classify(Double, Double) Obsolete.

Classifies a new instance into one of the available classes.

(Overrides BaseDiscriminantAnalysisClassify(Double, Double).) Compute Obsolete.

Computes the Multi-Class Linear Discriminant Analysis algorithm.

CreateDiscriminants

Creates additional information about principal components.

(Inherited from BaseDiscriminantAnalysis.) DiscriminantFunction

Gets the output of the discriminant function for a given class.

(Overrides BaseDiscriminantAnalysisDiscriminantFunction(Double, Int32).) Equals

Determines whether the specified object is equal to the current object.

(Inherited from Object.) Finalize

Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.

(Inherited from Object.) GetHashCode

Serves as the default hash function.

(Inherited from Object.) GetNumberOfDimensions

Returns the minimum number of discriminant space dimensions (discriminant factors) required to represent a given percentile of the data.

(Inherited from BaseDiscriminantAnalysis.) GetType

Gets the Type of the current instance.

(Inherited from Object.) init Obsolete.

Obsolete.

(Inherited from BaseDiscriminantAnalysis.) Init

Initializes common properties.

(Inherited from BaseDiscriminantAnalysis.) Learn

Learns a model that can map the given inputs to the given outputs.

MemberwiseClone

Creates a shallow copy of the current Object.

(Inherited from Object.) ToString

Returns a string that represents the current object.

(Inherited from Object.) Transform(Double) Obsolete.

Obsolete.

(Inherited from BaseDiscriminantAnalysis.) Transform(Double)

Applies the transformation to an input, producing an associated output.

(Inherited from BaseDiscriminantAnalysis.) Transform(Double)

Applies the transformation to an input, producing an associated output.

(Inherited from BaseDiscriminantAnalysis.) Transform(Double, Int32) Obsolete.

Obsolete.

(Inherited from BaseDiscriminantAnalysis.) Transform(Double, Int32) Obsolete.

Obsolete.

(Inherited from BaseDiscriminantAnalysis.) Transform(Double, Int32) Obsolete.

Obsolete.

(Inherited from BaseDiscriminantAnalysis.) Transform(Double, Double)

Applies the transformation to an input, producing an associated output.

(Overrides TransformBaseTInput, TOutputTransform(TInput, TOutput).) Top Extension Methods   Name Description HasMethod

Checks whether an object implements a method with the given name.

(Defined by ExtensionMethods.) IsEqual

Compares two objects for equality, performing an elementwise comparison if the elements are vectors or matrices.

(Defined by Matrix.) To(Type) Overloaded.

Converts an object into another type, irrespective of whether the conversion can be done at compile time or not. This can be used to convert generic types to numeric types during runtime.

(Defined by ExtensionMethods.) ToT Overloaded.

Converts an object into another type, irrespective of whether the conversion can be done at compile time or not. This can be used to convert generic types to numeric types during runtime.

(Defined by ExtensionMethods.) Top Remarks

Linear Discriminant Analysis (LDA) is a method of finding such a linear combination of variables which best separates two or more classes.

In itself LDA is not a classification algorithm, although it makes use of class labels. However, the LDA result is mostly used as part of a linear classifier. The other alternative use is making a dimension reduction before using nonlinear classification algorithms.

It should be noted that several similar techniques (differing in requirements to the sample) go together under the general name of Linear Discriminant Analysis. Described below is one of these techniques with only two requirements:

  1. The sample size shall exceed the number of variables, and
  2. Classes may overlap, but their centers shall be distant from each other.

Moreover, LDA requires the following assumptions to be true:

If the latter assumption is violated, it is common to use quadratic discriminant analysis in the same manner as linear discriminant analysis instead.

This class can also be bound to standard controls such as the DataGridView by setting their DataSource property to the analysis' Discriminants property.

References:

Examples
double[][] inputs = 
{
    
    new double[] {  4,  1 }, 
    new double[] {  2,  4 },
    new double[] {  2,  3 },
    new double[] {  3,  6 },
    new double[] {  4,  4 },

    
    new double[] {  9, 10 },
    new double[] {  6,  8 },
    new double[] {  9,  5 },
    new double[] {  8,  7 },
    new double[] { 10,  8 }
};

int[] output = 
{
    0, 0, 0, 0, 0, 
    1, 1, 1, 1, 1  
};


var lda = new LinearDiscriminantAnalysis();


var classifier = lda.Learn(inputs, output);


double[][] projection = lda.Transform(inputs);


int[] results = classifier.Decide(inputs);
See Also

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4