Description Usage Arguments Value Author(s) References See Also Examples
This function computes the polarisation measure proposed in Esteban and and Ray (1994).
1 | polarisation.ER(alpha, rho, comp = FALSE)
|
alpha |
a scalar containing the alpha parameter from Esteban and Ray (1994) on the sensitivity to polarisation. |
rho |
a dataframe with the group means in the first column and their respective population shares in the second. The groups need to be exogenously defined. Note: the two columns should be named |
comp |
logical; if TRUE, all components pf p_i^(a+alpha)*p_j*abs(y_i-y_j) |
P |
the polarisation measure proposed by Esteban and Ray (1994). |
means |
the means stored in rho. |
shares |
the shares stored in rho.. |
ERcomp |
if comp is TRUE, the components aggregated in P. |
Alexander Sohn
Esteban, J. and Ray, D. (1994): On the Measurment of Polarization, in: Econometrica, Vol. 62(4), pp. 819-851.
1 2 3 4 5 6 | means<-rnorm(10)+5
shares<- rep(1,length(means))
shares<-shares/sum(shares)
rho<-data.frame(means=means,shares=shares)
alpha<-1
polarisation.ER(alpha,rho,comp=FALSE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.