# Application with VIKOR multicriteria method

What to do in these cases where I can't rank by the VIKOR multicriteria method because Q has no value?

    library(MCDM)

df1<-structure(c(14509.9423478068, 4648.5779693212, 922, 876), .Dim = c(2L,
2L), .Dimnames = list(NULL, c("Criteria1", "Criteria2")))

> df1
Criteria1 Criteria2
[1,] 14509.942       922
[2,]  4648.578       876

w <- c(0.5,0.5)
cb <- c('min','max')
v <- 0.5
result1<-VIKOR(df1,w,cb,v)

> result1
Alternatives   S   R   Q Ranking
1            1 0.5 0.5 NaN       -
2            2 0.5 0.5 NaN       -

• Related but not a dupe: Using VIKOR multicriteria method in R Mar 16 at 22:36
• It is a different question @SecretAgentMan Mar 16 at 23:19
• Yes, which is why I said it is not a duplicate. My comment is intended to help future visitors find a related question. They may have similar questions as you. I hope they upvote both posts. Mar 17 at 12:58

If you look at the VIKOR paper of Opricovic & Tzeng (2004), you can see that $$Q$$ is defined as follows:
$$Q_j = v(S_j-S^*)/(S^--S^*) + (1-v)(R_j-R^*)/(R^--R^*)$$ where $$S^* = \min_j S_j, \quad S^-=\max_j S_j$$ $$R^* = \min_j R_j, \quad R^-=\max_j R_j$$
In your example, $$S_1$$ and $$S_2$$ are both $$0.5$$, therefore, $$S^*=0.5$$ and $$S^-=0.5$$ which leads to a division by zero and consequently, $$Q$$ is not defined. This holds not only for $$S$$ but also for $$R$$.