Description Usage Arguments Details Value See Also Examples
Función que calcula el NEP: indicador que provee un número "ajustado" de partidos políticos en un sistema de partídos (Function that computes NEP: indicator that provides a "tight" number of political parties in a party system)
1 | compute_nep(data, index = "All")
|
data |
la base de datos para hacer el cálculo obtenida con |
index |
un character con la fórmula elegida: "Laakso-Taagepera", "Golosov" o ambas -opción por defecto- (a character with the chosen formula: 'Laakso-Taagepera', 'Golosov' or both -dafault value). |
El computo solo se hace a partir de la cantidad de votos de cada lista y no de las bancas (The computation is only made from the number of votes for each ballot and not from the corresponding legislativa seats).
Impementación de las fórmulas "Laakso-Taagepera" y "Golosov" donde p_{1} es el porcentaje de votos de una lista i y p_{max} es el porcentaje de votos que sacó la lista más votada (Implementation of the "Laakso-Taagepera" and "Golosov" formulas, where p_{1} is vote percentage for a list i and p_{max} the percentage for the most voted party).
\large Laakso-Tagepera:
NEP_{Laakso-Tagepera}=\frac{1}{∑_{i}^{n}p_{i}^2}
\large Golosov:
NEP_{Golosov}=\frac{p_{i}}{∑_{i}^{n} p_{i}+p_{max}^2-p_{i}^2}
REQUISITO:
El formato de data
debe ser long
para calcular compute_nep
.
Si data
es wide se puede transformar con make_long
(long
format of data
is required for compute_nep
.
If data
is in wide format you can transform it with make_long
)
NOTA:
el parámetro level
de get_election_data
determina el nivel de agregacion sobre el que
se computa el NEP: provincia
, departamento
o circuito
(level
at get_election_data
determines aggregation on which NEP calculation
will be made: provincia
, departamento
or circuito
).
Devuelve un tibble con class "tbl_df","tbl", "data.frame"
de dimensiones variables seguún el nivel de agrupamiento de
data
con el cómputo del número ajustado de fuerzas en un sistema de partidos
(Returns a tibble with class "tbl_df", "tbl", "data.frame"
, of variable dimensions according to the grouping level of
data
with a "tight" numero of political parties in a party system as outcome).
Como minimo tres variables (At least three variables:):
*codprov
que es el agrupamiento de más alto nivel (provincial). Se pueden sumar otros niveles:
coddepto
para nivel departamental y circuito
para el nivel que le sigue
(codprov
which is the highest level grouping -provincial. Other levels can be added:
coddepto
for departmental level and circuito
for the level that follows).
* value
: el valor calculado del NEP (NEP computation)
* index
: el método utilizado para calcular el NEP (NEP methodology used for computation)
compute_competitiveness, compute_seats, compute_disproportion
1 2 3 4 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.