I’m using Clustering Pkg and function fuzzy_cmean, and try to assign the cluster number to each data.
If I use findmax(FuzzyCMeansResult.weights, dims=2)
will give us (value, CartesianIndex(2)).
Then, I cannot find out how to use CartesianIndex(2)
values for real data.
For example, sometimes it will give us:
CartesianIndex(1, 20)
CartesianIndex(2, 19)
…
CartesianIndex(601, 19)
CartesianIndex(602, 11)
I hope to use CartesianIndex(2) 2nd value for candidate cluster for each data.
So, how to convert CartesianIndex values to Int64?