pcca | R Documentation |
Using must-link and cannot-link constaints, PCCA (Mignon & Jury, 2012) learns a projection into a low-dimensional space where the distances between pairs of data points respect the desired constraints, exhibiting good generalization properties in presence of high dimensional data.
pcca(x, d1, ML, CL, options = c(1, 1000, 1e-05, 10), beta = 1)
x |
Data matrix of size n*d |
d1 |
Number of extracted features. |
ML |
Matrix nbML x 2 of must-link constraints. Each row of ML contains the indices of objects that belong to the same class. |
CL |
Matrix nbCL x 2 of cannot-link constraints. Each row of CL contains the indices of objects that belong to different classes. |
options |
Parameters of the optimization algorithm (see |
beta |
Sharpness parameter in the loss function (default: 1). |
A list with three attributes:
The n*d1 matrix of extracted features.
The projection matrix of size d1*d.
The Euclidean distance matrix in the projected space
Thierry Denoeux.
A. Mignon and F. Jurie. PCCA: a new approach for distance learning from sparse pairwise constraints. In 2012 IEEE Conference on Computer Vision and Pattern Recognition, pages 2666-2672, 2012.
kpcca
,harris
,create_MLCL
## Not run:
data(iris)
x<-as.matrix(iris[,1:4])
y<-as.integer(iris[,5])
const<-create_MLCL(y,50)
res.pcca<-pcca(x,1,const$ML,const$CL)
plot(res.pcca$z,col=y,pch=y)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.