library(UniversalCVI)
# Iris data
x = iris[,1:4]
# ----Compute all the indices by FzzyCVIs ----
FCVIs = FzzyCVIs(scale(x), cmax = 10, cmin = 2, indexlist = 'all', corr = 'pearson',
method = 'FCM', fzm = 2, iter = 100, nstart = 20, NCstart = TRUE)
# plots of the eight indices by default
plot_idx(idxresult = FCVIs)
# plots of a specific selected.idx
plot_idx(idxresult = FCVIs, selected.idx = c(2,5,7))
# ----Compute all the indices by Wvalid ----
FCM.NC = Wvalid(scale(x), kmax = 10, kmin=2, method = 'kmeans',
corr='pearson', nstart=100, NCstart = TRUE)
# plots of the four indices by default
plot_idx(idxresult = FCM.NC)
# ----Compute all the indices by XB.IDX ----
FCM.XB = XB.IDX(scale(x), cmax = 10, cmin = 2, method = "FCM",
fzm = 2, nstart = 20, iter = 100)
plot_idx(idxresult = FCM.XB)
Run the code above in your browser using DataLab