From 616b10d4658d09d5a12ccf1c598b33e90e7f496d Mon Sep 17 00:00:00 2001
From: giorgiacek
severity <- pipgd_pov_severity(welfare = pip_gd$L,
- weight = pip_gd$P,
- mean = mu,
- povline = z,
- lorenz = 'lq')
+ weight = pip_gd$P,
+ mean = mu,
+ povline = z,
+ lorenz = 'lq')
print((paste0("The poverty severity is ", round(severity$pov_severity*100,2), "%")))
#> [1] "The poverty severity is 4.75%"
Finally, pipster
can also be used to easily calculate
+additional inequality measures. The Gini coefficient can be calculated
+using pipgd_gini()
like so:
+gini <- pipgd_gini(welfare = pip_gd$L,
+ weight = pip_gd$P,
+ lorenz = 'lq')
+
+print((paste0("The gini index is ", round(gini$dist_stats$gini,2))))
+#> [1] "The gini index is 0.29"
The Watts Index can be calculated using pipgd_watts()
+like so:
+watts <- pipgd_watts(welfare = pip_gd$L,
+ weight = pip_gd$P,
+ mean = mu,
+ povline = z,
+ lorenz = 'lq')
+
+print((paste0("The Watts index is ", round(watts$watts, 2))))
+#> [1] "The Watts index is 0.43"
And finally, the MLD (Mean Logarithmic Deviation) can be calculated
+using pipgd_mld()
like so: