Cluster data into two classes using SOM

11 次查看(过去 30 天)
I need to Cluster data of 1200 vectors (1200 X 500) using SOM in two dimensions x and y, so that X and y are separated with line to describe the 2 classes, the main class and the out-layers. I have written the following code for this purpose, but i feel i am not receiving the required results. Your Help is much appreciated.
clc
filename = 'FFW.txt';
delimiterIn = '\t';
All= importdata(filename,delimiterIn);
% data - input data.
x = All.data;
% Create a Self-Organizing Map with 100 Neuron grid
dimension1 = 10;
dimension2 = 10;
net = selforgmap([dimension1 dimension2]);
% Train the Network on 50% of the input data
net.trainParam.epochs = 2;
[net,tr] = train(net,x);
% Test the Network on 50% of the input data different from training data
y = net(x);
% View the Network
view(net);
% Plots : The result shows two main clusters in the resulting data
figure, plotsomnd(net);
Thank you Hope

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Function Approximation, Clustering, and Control 的更多信息

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by