Learn R Programming

SSL (version 0.1)

sslLDS: Low Density Separation

Description

sslLDS implements low density separation with Transductive Support Vector Machines(TSVM) for semi-supervised binary classification

Usage

sslLDS(xl, yl, xu, rho = 1, C = 1, dist.type = "Euclidean", p = 0.3, improvement = 1e-04, seed = 0, delta = 0.01, alpha = 0.01)

Arguments

xl
a n * p matrix or data.frame of labeled data
yl
a n * 1 binary labels(1 or -1).
xu
a m * p matrix or data.frame of unlabeled data.
rho
numeric;a parameter for connectivity kernel.It defines minimal rho-path distances.
C
numeric; a parameter in the TSVM training model.
dist.type
character string; this parameter controls the type of distance measurement.(see dist or pr_DB).
p
the percentage of data used for cross-validation set.
improvement
numeric; minimal allowed improvement of parameters.
seed
an integer specifying random number generation state for spliting labeled data into training set and cross-validation set.
delta
numeric; a allowed cutoff for the cumulative percent of variance to lose by multidimensional scaling.
alpha
numeric; a learning rate in the gradient descent algorithm.

Value

a list of values is returned:

Fields

yu
the predicted label of unlabeled data
optC.star
the optimal C.star chosen by cross-validation. C.star weights the unlabeled data in the TSVM model.
para
estimated parameters of TSVM, including w and b

Details

sslLDS constructs a low density graph with connectivity kernel.It implements multidemensional scaling for demensionality reduction and chooses optimal C.star by cross-validation. Finally, it trains the TSVM model with gradient descent algorithm.

References

Chapelle, O., & Zien, A. (2005) Semi-supervised classification by low density separation.In Proceedings of the tenth international workshop on artificial intelligence and statistics.(pp. 57-64). Barbados.

Examples

Run this code
data(iris)
xl<-iris[c(1:20,51:70),-5]
xu<-iris[c(21:50,71:100),-5]
yl<-rep(c(1,-1),each=20)
l<-sslLDS(xl,yl,xu,alpha=0.1)

Run the code above in your browser using DataLab