How do I find the indices of the Self Organizing Map (SOM) training set output

4 次查看(过去 30 天)
I'm using the SOM toolbox and have created the following:
net = selforgmap([10 10)];
[net,tr] = train(net,inputs);
where 'inputs' is a 5x10000 matrix of 5 parameters with 10000 samples.
using plotsomhits(net,inputs); shows how the 10000 samples are getting clustered.
Question: How do I output where each individual vector is clustered? For example where on the 10x10 grid is vector #1 located?
TIA
Scott

采纳的回答

Shashank Prasanna
编辑:Shashank Prasanna 2013-8-5
Here is an example that should help you:
net = selforgmap([10 10]);
[net,tr] = train(net,inputs); % Classify input data
op_som = vec2ind(net(inputs))';
for each input in inputs, op_som will have a numbering between 1 to n based on which cluster it belongs to.

更多回答(2 个)

Scott
Scott 2013-8-6
Works great, thanks Shashank! Scott

YILMAZ KAYA
YILMAZ KAYA 2020-8-25
It works. Thanks so much....

类别

Help CenterFile Exchange 中查找有关 Pattern Recognition and Classification 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by