I'm very confused, when I read on the wikipedia "From a mathematical standpoint, Rand index is related to the accuracy, but is applicable even when class labels are not used." Here and the formula of the Rand Index here
But when I use in R the rand.index function from fossil package and the Accuracy function from MLmetrics it doesn't give the same answer
> Accuracy(predicted, real)
Please can someone explain to me the difference between these two and which one should I use?
NB:I use the k-medoids clustering algorithm (function pam from cluster package)