Description Usage Arguments Value Examples
View source: R/Electoral_index.R
Loosemore and Hanby disproportionality index ( 1971 ) aims to address the difficulties encountered with the Rae index. To calculate this disproportionality index, the absolute values of the differences between votes and seats are added together and the result is divided by two. The specific formula used is as follows: '
LH = (1/2)*sum(|Vi-Ei|)
for i = 1, 2, …,n
1 | Loos_Hanby(votes, seats)
|
votes |
It is a vector of integers, containing the votes of all the candidates. |
seats |
It is a vector of integers, containing the seats obtained by each of the candidates. |
Returns the value obtained for the index
1 | Loos_Hanby(c(1200, 30, 4000),c(10,6,8))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.