data("Chainlink")
Data=Chainlink$Data
Cls=Chainlink$Cls
InputDistances=as.matrix(dist(Data))
res=cmdscale(d=InputDistances, k = 2, eig = TRUE, add = FALSE, x.ret = FALSE)
ProjectedPoints=as.matrix(res$points)
#see also ProjectionBasedClustering package for other common projection methods
# \donttest{
resUmatrix=GeneralizedUmatrix(Data,ProjectedPoints)
## Normalization
normalizedUmatrix=NormalizeUmatrix(Data,resUmatrix$Umatrix,resUmatrix$Bestmatches)
## visualization
TopviewTopographicMap(GeneralizedUmatrix = normalizedUmatrix,resUmatrix$Bestmatches)
# }
# \dontshow{
if(requireNamespace('deldir',quietly = TRUE)) {
resUmatrix=GeneralizedUmatrix(Data[1:2,],ProjectedPoints[1:2,])
normalizedUmatrix=NormalizeUmatrix(Data[1:2,],resUmatrix$Umatrix, resUmatrix$Bestmatches)
}
# }
Run the code above in your browser using DataLab