Skip to contents

Get the cluster label(result) of GeoSOM model.

Usage

geosom_clusterlabel(gsom, superclass)

Arguments

gsom

A kohonen object,get from geosom().

superclass

A numeric vector get form geosom_superclass()

Value

A numeric vector representing the cluster label.

Author

Wenbo Lv lyu.geosocial@gmail.com

Examples

data(pmc)
g = geosom(data = pmc, coords = c("centroidx","centroidy"),
wt = 3,grid = geosomgrid(6,10),normalize = TRUE)
g_superclass = geosom_superclass(g,12)
g_label = geosom_clusterlabel(g,g_superclass)
g_label
#>   [1]  7 10  4  3  9  1  6  9  6  5  2  6  7  4  1  2  5  4  2  2  2  3 10  2  8
#>  [26] 11 10  9 10 10  7  4 11  2  2  8  9  3  6 11 12  3  5  9  2  4  6  6  3  4
#>  [51] 12  7 11  6  6 10  2  9  4  4  6  8 10  7 11  4 11  2  2  4 11  2  4 11  9
#>  [76]  9  7  2  4  4  2  3  9  5 12  9  3  2 11  1 11  2 10  9  7 10  4  7  3  4
#> [101]  3  7  9 12  4  2  4 11  7  9  1  1 11  9  8  1  8  6  9 11  7  7  8  5  4
#> [126]  4 11  9  4  5  9  7 10  2 11  9  9  7  7  7  4  5 10  1 11  3 11  6  9  6
#> [151]  2 10  3  3  4  9  6  4  7  6  1  8  8  7  1  5 10  9  4  9  1  5 12  5  7
#> [176] 12 10 10  9 12  4  4  4 10  6 11  4  9 10 10  3  2  3  1  5  9 11 12  7  3
#> [201]  3 11 11  6  4  4  6 10  5 11  9  2 11  1  5  4 11  7  4  4  5  4  3 10  5
#> [226]  5 10  1  1  8  8  9  3  4  4 11  1 11 10 10  7  9  6  7  5  9  5 10  5  4
#> [251]  6  2 10  3 11 10  1 12  7  6  9 10 12  7  5 11  9  4 11  1  7 10  3  7  4
#> [276] 11 11 10