Last data update: 2014.03.03

R: Locally Linear Embedding
LLER Documentation

Locally Linear Embedding

Description

Computes the Locally Linear Embedding as introduced in 2000 by Roweis, Saul and Lawrence.

Usage

LLE(data, dim=2, k)

Arguments

data

N x D matrix (N samples, D features)

dim

dimension of the target space

k

number of neighbours

Details

Locally Linear Embedding (LLE) preserves local properties of the data by representing each sample in the data by a linear combination of its k nearest neighbours with each neighbour weighted independently. LLE finally chooses the low-dimensional representation that best preserves the weights in the target space.
This R version is based on the Matlab implementation by Sam Roweis.

Value

It returns a N x dim matrix (N samples, dim features) with the reduced input data

Author(s)

Christoph Bartenhagen

References

Roweis, Sam T. and Saul, Lawrence K., "Nonlinear Dimensionality Reduction by Locally Linear Embedding",2000;

Examples

## two dimensional LLE embedding of a 1.000 dimensional dataset using k=5 neighbours
d = generateData(samples=20, genes=1000, diffgenes=100, blocksize=10)
d_low = LLE(data=d[[1]], dim=2, k=5)

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(RDRToolbox)
> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/RDRToolbox/LLE.Rd_%03d_medium.png", width=480, height=480)
> ### Name: LLE
> ### Title: Locally Linear Embedding
> ### Aliases: LLE
> 
> ### ** Examples
> 
> ## two dimensional LLE embedding of a 1.000 dimensional dataset using k=5 neighbours
> d = generateData(samples=20, genes=1000, diffgenes=100, blocksize=10)
> d_low = LLE(data=d[[1]], dim=2, k=5)
Computing distance matrix ... done
Computing low dimensional emmbedding (using 5 nearest neighbours)... done
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>