Slide 16
Slide 16 text
書き方
# 色と記号の設定
COL <- c("#FF3300", "#339966", "#0041FF")
BGC <- c("#FFFF99", "#76E4A6", "#B4EBFA")
SP <- as.numeric(iris[,5])
LBL <- c("se","ve","vi")
# マップ
plot(iris.som, type="mapping", labels=LBL[SP], col=COL[SP], bg=BGC[1])
# ユニットごとの個体数
plot(iris.som, type="counts")
# 収束の様子
plot(iris.som, type="changes")
# ユニットをクラスタリングして色づけ
BGC <- c("#FFFF99", "#76E4A6", "#B4EBFA")
iris.som.dist <- dist(iris.som$codes)^2
CLST <-cutree(hclust(iris.som.dist,"ward"),3)
plot(iris.som, type="mapping", labels=LBL[SP], col=COL[SP], bgcol=BGC[CLST])