Learn R Programming

lfda (version 1.1.3)

lfda: Local Fisher Discriminant Analysis for Supervised Dimensionality Reduction

Description

Performs local fisher discriminant analysis (LFDA) on the given data.

Usage

lfda(x, y, r, metric = c("orthonormalized", "plain", "weighted"),
  knn = 5)

Arguments

x

n x d matrix of original samples. n is the number of samples.

y

length n vector of class labels

r

dimensionality of reduced space (default: d)

metric

type of metric in the embedding space (no default) 'weighted' --- weighted eigenvectors 'orthonormalized' --- orthonormalized 'plain' --- raw eigenvectors

knn

parameter used in local scaling method (default: 5)

Value

list of the LFDA results:

T

d x r transformation matrix (Z = x * T)

Z

n x r matrix of dimensionality reduced samples

Details

LFDA is a method for linear dimensionality reduction that maximizes between-class scatter and minimizes within-class scatter while at the same time maintain the local structure of the data so that multimodal data can be embedded appropriately. Its limitation is that it only looks for linear boundaries between clusters. In this case, a non-linear version called kernel LFDA will be used instead. Three metric types can be used if needed.

References

Sugiyama, M (2007). Dimensionality reduction of multimodal labeled data by local Fisher discriminant analysis. Journal of Machine Learning Research, vol.8, 1027--1061.

Sugiyama, M (2006). Local Fisher discriminant analysis for supervised dimensionality reduction. In W. W. Cohen and A. Moore (Eds.), Proceedings of 23rd International Conference on Machine Learning (ICML2006), 905--912.

See Also

See klfda for the kernelized variant of LFDA (Kernel LFDA).

Examples

Run this code
# NOT RUN {
k <- iris[, -5]
y <- iris[, 5]
r <- 3
lfda(k, y, r, metric = "plain")
# }

Run the code above in your browser using DataLab