CensusMapper's gini(): the Gini coefficient from counts per income
bracket and the brackets' lower cutoffs, one value per region. Incomes are
taken at the bracket midpoints. The top bracket's income is twice its lower
cutoff less the previous cutoff, or is estimated from the total income when
that is given.
Arguments
- counts
Counts per bracket: a matrix with one row per region and one column per bracket, e.g.
cbind(v1, v2, v3)insidedplyr::mutate().- lower_cutoffs
The brackets' lower cutoffs, a vector that is the same for every region, or a matrix like
counts.- total
Total income per region, or 0 (the default) for none.
