Code covered by the BSD License  

Highlights from
Recognizing Far-Near Relations of Clusters by GDEM, Visualization by Line-Pearl Pattern

image thumbnail

Recognizing Far-Near Relations of Clusters by GDEM, Visualization by Line-Pearl Pattern

by

 

21 Aug 2010 (Updated )

measure far-near degrees (distances) between clusters & dense degrees of border regions of clusters

data_load(sw,alabel,nrow,simatrix,aready)
function [data,similarity,truelabels,nrow] = data_load(sw,alabel,nrow,simatrix,aready)

truelabels = ones(nrow,1);
data = [];
similarity =[];      % given similarity matrix
if simatrix == 1 || aready
    load(sw);
    if exist('X','var') data=X; truelabels=y; end
    if ~nrow
        nrow = size(data,1);
    end
else
    data = load(sw);
    if ~nrow
        [nrow, dim] = size(data);
    end
    % taking true class labels from a data file
    if alabel
        truelabels = data(:,1);
        data = data(:,2:dim);
    end
end
if size(truelabels,2) > 1
    truelabels = truelabels';
end

Contact us