Package {agriEquity}


Type: Package
Title: Equity and Sustainability Assessment of Agricultural Subsidies
Version: 0.1.0
Description: An integrated framework for evaluating whether agricultural support measures reach smallholders, women farmers and resource-poor regions, and at what productivity and environmental cost. It provides survey-weighted benefit incidence analysis by landholding class, gender, region or income quantile; concentration, Kakwani and Reynolds-Smolensky progressivity measures (Kakwani, 1977) <doi:10.2307/2230485> with bootstrap confidence intervals; multi-dimensional equity scorecards with parity ratios and Theil decomposition of benefit inequality; effects of subsidies on income inequality and Foster-Greer-Thorbecke poverty (Foster, Greer and Thorbecke, 1984) <doi:10.2307/1913475>; budget-neutral reallocation of a subsidy budget under alternative allocation rules, including a welfare-optimal allocation that combines diminishing productivity returns, Atkinson (1970) <doi:10.1016/0022-0531(70)90039-6> inequality aversion and environmental damage costs; and productivity-equity-sustainability trade-off frontiers. Simulated farm-household data illustrate the workflow.
License: GPL (≥ 3)
Encoding: UTF-8
Language: en-GB
LazyData: true
Depends: R (≥ 3.5.0)
Imports: graphics, stats
Suggests: knitr, rmarkdown, testthat (≥ 3.0.0)
VignetteBuilder: knitr
Config/testthat/edition: 3
RoxygenNote: 7.3.1
NeedsCompilation: no
Packaged: 2026-10-15 10:08:23 UTC; root
Author: Anbukkani Perumal [aut, cre, cph]
Maintainer: Anbukkani Perumal <anbueconomic@gmail.com>
Repository: CRAN
Date/Publication: 2026-10-24 12:00:02 UTC

agriEquity: Equity and Sustainability Assessment of Agricultural Subsidies

Description

An integrated framework for distributional analysis of agricultural support, budget-neutral subsidy allocation and productivity-equity-sustainability trade-offs.

Details

* [benefit_incidence()] - who receives the subsidy, by group or quantile. * [progressivity_index()] - concentration, Kakwani and Reynolds-Smolensky measures. * [subsidy_equity()] - multi-dimensional equity scorecard with Theil decomposition. * [distributional_effects()] - inequality and poverty with and without the subsidy, for one or more scenarios. * [budget_reallocation()] - budget-neutral allocation rules, including a welfare-optimal allocation. * [tradeoff_frontier()] - productivity-equity-sustainability frontier.

The example data set [farm_subsidy] is simulated.

Author(s)

Maintainer: Anbukkani Perumal anbueconomic@gmail.com [copyright holder]


Benefit incidence analysis of agricultural support

Description

Shows how a subsidy or support payment is distributed across groups of farm households: landholding classes, gender of the farmer, regions, or quantiles of income or landholding. For each group the function reports its (weighted) share of farm households, its share of total benefits, the parity ratio (benefit share divided by population share; values below 1 mean the group receives less than its population share), the coverage rate (share of households receiving any benefit), the mean benefit per household and per beneficiary, and, if supplied, the mean benefit per hectare and benefits as a share of group income.

Usage

benefit_incidence(
  data,
  benefit,
  group = NULL,
  rank_var = NULL,
  n_quantiles = 5,
  weights = NULL,
  area = NULL,
  income = NULL
)

Arguments

data

A data frame with one row per farm household.

benefit

Name of the column with the benefit received (currency per household per year; zero for non-recipients).

group

Name of a grouping column (for example landholding class). Alternatively use 'rank_var'.

rank_var

Name of a column (for example income or land) used to form weighted quantile groups when 'group' is 'NULL'.

n_quantiles

Number of quantile groups for 'rank_var'.

weights

Optional name of a survey-weight column.

area

Optional name of an operated-area column (hectares).

income

Optional name of an income column.

Value

A data frame of class 'benefit_incidence', one row per group, with columns 'group', 'households', 'population_share', 'benefit_share', 'parity_ratio', 'coverage', 'mean_benefit_per_household', 'mean_benefit_per_beneficiary' and, when available, 'benefit_per_hectare' and 'benefit_income_ratio'.

Examples

benefit_incidence(farm_subsidy, "fertiliser_subsidy",
                  group = "size_class", weights = "weight",
                  area = "land_ha", income = "farm_income")
benefit_incidence(farm_subsidy, "income_transfer",
                  rank_var = "farm_income", weights = "weight")

Budget-neutral reallocation of agricultural support

Description

Redistributes a fixed support budget among farm households under alternative allocation rules and evaluates every allocation on the same productivity, equity and sustainability metrics, so that reforms can be compared at equal fiscal cost.

Usage

budget_reallocation(
  income,
  current,
  weights = NULL,
  budget = NULL,
  area = NULL,
  priority = NULL,
  target = NULL,
  return_rate = 0,
  saturation = NULL,
  env_cost = 0,
  inequality_aversion = 1,
  env_weight = 1,
  area_cap = 2,
  max_per_farm = Inf,
  poverty_line = NULL,
  income_floor = NULL,
  rules = c("current", "per_farm", "per_hectare", "per_hectare_capped", "targeted",
    "optimal")
)

Arguments

income

Pre-support household income.

current

Current support received per household.

weights

Optional survey weights.

budget

Budget to allocate (weighted total); defaults to the current total, which makes the comparison budget-neutral.

area

Optional operated area (ha) for area-based rules.

priority

Optional non-negative priority score per household for the targeted rule.

target

Optional logical vector marking priority households (smallholders, women, resource-poor regions) for the target share metric.

return_rate

Marginal productivity return r_i (scalar or one per household).

saturation

Saturation scale k_i; defaults to the budget per household.

env_cost

Environmental cost per unit of support e_i.

inequality_aversion

Atkinson inequality aversion \varepsilon \ge 0.

env_weight

Weight \lambda on environmental cost.

area_cap

Area cap (ha) for the capped per-hectare rule.

max_per_farm

Upper limit of support per household in the optimal rule.

poverty_line

Optional poverty line.

income_floor

Optional floor applied to incomes (needed when some incomes are zero or negative and 'inequality_aversion' > 0).

rules

Allocation rules to evaluate.

Details

**Rules.** '"current"' (the existing distribution, rescaled to the budget), '"per_farm"' (equal amount per household), '"per_hectare"' (proportional to operated area), '"per_hectare_capped"' (proportional to area up to 'area_cap' hectares), '"targeted"' (proportional to a household priority score, for example higher for marginal farmers, women and resource-poor regions) and '"optimal"'.

**Household model.** A household receiving support s_i gains the transfer itself plus an additional productivity response with diminishing returns,

q_i(s_i) = r_i k_i \ln(1 + s_i / k_i),

where r_i is the marginal output value of the first unit of support (for example from better input use) and k_i a saturation scale. Support also causes an environmental cost e_i s_i (for example the damage value of nutrient surplus or groundwater depletion induced by input or power subsidies).

**Optimal rule.** Shares s_i \ge 0 with \sum_i w_i s_i = B maximise

\sum_i w_i U(y_i + s_i + q_i(s_i)) - \lambda \sum_i w_i e_i s_i,

where U has constant inequality aversion \varepsilon (Atkinson, 1970) normalised so that the marginal welfare weight at mean income is 1. \varepsilon = 0 values all income equally (pure efficiency); larger \varepsilon gives more weight to poorer households. \lambda is the weight on environmental cost. The solution equalises marginal social value across households and is found by nested bisection on the budget multiplier.

**Metrics.** Budget, productivity gain (total q_i), productivity per unit of budget, environmental cost, net social value (productivity gain minus environmental cost), Gini of post-support income, concentration index of support by income, Atkinson equally distributed equivalent income and its gain, share of support reaching 'target' households, and optionally poverty headcount and gap.

Value

A list of class 'budget_reallocation' with 'metrics' (one row per rule), 'allocations' (data frame of support per household under each rule) and 'params'.

References

Atkinson, A. B. (1970). On the measurement of inequality. *Journal of Economic Theory*, 2(3), 244-263. doi:10.1016/0022-0531(70)90039-6

Examples

fs <- farm_subsidy
prio <- with(fs, 1 + (size_class %in% c("marginal", "small")) +
               0.5 * (gender == "female") +
               0.5 * (region %in% c("Rainfed-East", "Hill-Tribal")))
br <- budget_reallocation(fs$farm_income, fs$fertiliser_subsidy,
                          weights = fs$weight, area = fs$land_ha,
                          priority = prio,
                          target = fs$size_class %in% c("marginal", "small"),
                          return_rate = fs$marginal_return,
                          env_cost = fs$env_cost_per_rupee,
                          inequality_aversion = 1, env_weight = 1,
                          poverty_line = 60000)
br

Distributional effects of subsidies on income, inequality and poverty

Description

Compares farm household income without support with income including the benefits under one or more subsidy scenarios. For each scenario it reports mean income, the Gini coefficient, the redistributive effect, the Foster-Greer-Thorbecke poverty measures FGT_0 (headcount), FGT_1 (poverty gap) and FGT_2 (severity) at the given poverty line, the share of households lifted out of poverty, and the cost per household lifted. A quantile table shows mean benefit and the percentage income gain in each quantile of pre-subsidy income.

Usage

distributional_effects(
  income,
  benefits,
  weights = NULL,
  poverty_line,
  n_quantiles = 5
)

Arguments

income

Numeric vector of pre-subsidy household income.

benefits

A numeric vector of benefits, or a named list (or data frame) of benefit vectors, one per scenario.

weights

Optional survey weights.

poverty_line

Poverty line in the same units as income.

n_quantiles

Number of income quantiles in the quantile table.

Value

A list of class 'distributional_effects' with 'summary' (one row per scenario plus the no-support baseline) and 'by_quantile' (mean benefit and percentage income gain by pre-subsidy income quantile and scenario).

References

Foster, J., Greer, J. and Thorbecke, E. (1984). A class of decomposable poverty measures. *Econometrica*, 52(3), 761-766. doi:10.2307/1913475

Examples

de <- with(farm_subsidy, distributional_effects(
  farm_income,
  list(fertiliser = fertiliser_subsidy, transfer = income_transfer,
       power = power_subsidy),
  weights = weight, poverty_line = 60000))
de

Simulated farm-household data on agricultural support

Description

A synthetic cross-section of 1,500 farm households generated by 'data-raw/make_data.R' to illustrate the package. Support, income, productivity-return and environmental-cost values are simulated and are not estimates for any country, scheme or survey.

Usage

farm_subsidy

Format

A data frame with 1,500 rows and 12 columns:

household

Household identifier.

region

'"Irrigated-North"', '"Irrigated-South"', '"Rainfed-East"' or '"Hill-Tribal"'; the last two represent resource-poor regions.

gender

Gender of the principal farmer ('"female"', '"male"').

land_ha

Operated area, hectares.

size_class

Landholding class: marginal (< 1 ha), small (1-2), semi-medium (2-4), medium (4-10) or large (>= 10).

farm_income

Annual household farm income before support (currency units).

fertiliser_subsidy

Input (fertiliser) subsidy received.

income_transfer

Flat direct income transfer received.

power_subsidy

Irrigation power subsidy received.

marginal_return

Marginal output value per unit of additional support (simulated).

env_cost_per_rupee

Environmental damage cost per unit of input support (simulated).

weight

Survey weight.

Source

Simulated.


Plot a productivity-equity-sustainability frontier

Description

Plot a productivity-equity-sustainability frontier

Usage

## S3 method for class 'tradeoff_frontier'
plot(x, ...)

Arguments

x

A [tradeoff_frontier()] object.

...

Further arguments passed to [graphics::plot()].

Value

'x', invisibly.

Examples

fs <- farm_subsidy[1:300, ]
plot(tradeoff_frontier(fs$farm_income, fs$fertiliser_subsidy,
                       weights = fs$weight, return_rate = 0.3,
                       aversion = c(0, 2), env_weights = 0))

Progressivity of agricultural support

Description

Measures whether a benefit is distributed progressively with respect to a welfare ranking variable such as household income or landholding.

Concentration index C_b

of the benefit, ranking households by 'rank_by'. Negative values mean the benefit is concentrated among the poorer (or smaller) households in absolute terms.

Gini G_x

of pre-subsidy income.

Kakwani index

K = G_x - C_b (Kakwani, 1977), positive when the benefit is distributed more equally than income, i.e. relatively progressive.

Redistributive effect

RE = G_x - G_{x+b}, decomposed into the vertical (Reynolds-Smolensky) effect G_x - C_{x+b} and re-ranking G_{x+b} - C_{x+b}.

Concentration and Gini indices are computed with survey weights using the covariance formula. Optional bootstrap confidence intervals resample households with replacement (set a seed beforehand for reproducibility).

Usage

progressivity_index(
  benefit,
  income,
  rank_by = income,
  weights = NULL,
  n_boot = 0,
  conf = 0.95
)

Arguments

benefit

Numeric vector of benefits per household.

income

Numeric vector of pre-subsidy income per household.

rank_by

Ranking variable for the concentration index; defaults to 'income'. Use landholding to assess progressivity by farm size.

weights

Optional survey weights.

n_boot

Number of bootstrap replications (0 for none).

conf

Confidence level for bootstrap intervals.

Value

A list of class 'progressivity_index' with 'estimates' (named vector of the indices) and, if 'n_boot > 0', 'ci' (bootstrap percentile intervals) and an 'interpretation' string.

References

Kakwani, N. C. (1977). Measurement of tax progressivity: an international comparison. *The Economic Journal*, 87(345), 71-80. doi:10.2307/2230485

Reynolds, M. and Smolensky, E. (1977). *Public Expenditures, Taxes, and the Distribution of Income: The United States, 1950, 1961, 1970*. Academic Press, New York.

Examples

with(farm_subsidy, progressivity_index(fertiliser_subsidy, farm_income,
                                       weights = weight))
set.seed(1)
with(farm_subsidy, progressivity_index(income_transfer, farm_income,
                                       weights = weight, n_boot = 99))

Multi-dimensional equity scorecard for agricultural support

Description

Assesses a subsidy along several equity dimensions at once, for example landholding class, gender of the farmer and region. For each dimension and group it reports population and benefit shares, the parity ratio (benefit share / population share), coverage, and mean benefit per household relative to a reference group. Inequality of benefits across households is measured by the Theil index and decomposed into between-group and within-group components for each dimension, so the share of benefit inequality explained by farm size, gender or region can be compared.

Usage

subsidy_equity(
  data,
  benefit,
  dimensions,
  weights = NULL,
  reference = NULL,
  target = NULL
)

Arguments

data

A data frame with one row per household.

benefit

Name of the benefit column.

dimensions

Character vector of grouping columns (for example 'c("size_class", "gender", "region")').

weights

Optional name of a survey-weight column.

reference

Optional named list giving, for each dimension, the reference group for relative benefits (default: the group with the highest mean benefit).

target

Optional named list giving, for each dimension, the priority groups (for example smallholders, women, resource-poor regions) whose combined parity ratio is reported.

Details

A summary row per dimension gives the minimum parity ratio (the most under-served group), the between-group Theil share and the target-group parity when 'target' groups are named.

Value

A list of class 'subsidy_equity' with 'groups' (data frame by dimension and group) and 'summary' (one row per dimension).

Examples

se <- subsidy_equity(farm_subsidy, "fertiliser_subsidy",
                     dimensions = c("size_class", "gender", "region"),
                     weights = "weight",
                     target = list(size_class = c("marginal", "small"),
                                   gender = "female",
                                   region = c("Rainfed-East",
                                              "Hill-Tribal")))
se

Productivity-equity-sustainability trade-off frontier

Description

Solves the welfare-optimal budget-neutral allocation of [budget_reallocation()] over a grid of inequality-aversion and environmental-weight values and records the resulting productivity gain, environmental cost, post-support Gini, target-group share and poverty. Plotting productivity against equity for each environmental weight shows how much output must be given up for a more equal, or a less environmentally damaging, allocation of the same budget, and where the current allocation lies relative to the frontier.

Usage

tradeoff_frontier(
  income,
  current,
  weights = NULL,
  budget = NULL,
  target = NULL,
  return_rate = 0,
  saturation = NULL,
  env_cost = 0,
  aversion = c(0, 0.5, 1, 2, 3),
  env_weights = c(0, 1, 2),
  max_per_farm = Inf,
  poverty_line = NULL,
  income_floor = NULL
)

Arguments

income

Pre-support household income.

current

Current support received per household.

weights

Optional survey weights.

budget

Budget to allocate (weighted total); defaults to the current total, which makes the comparison budget-neutral.

target

Optional logical vector marking priority households (smallholders, women, resource-poor regions) for the target share metric.

return_rate

Marginal productivity return r_i (scalar or one per household).

saturation

Saturation scale k_i; defaults to the budget per household.

env_cost

Environmental cost per unit of support e_i.

aversion

Values of inequality aversion \varepsilon.

env_weights

Values of the environmental weight \lambda.

max_per_farm

Upper limit of support per household in the optimal rule.

poverty_line

Optional poverty line.

income_floor

Optional floor applied to incomes (needed when some incomes are zero or negative and 'inequality_aversion' > 0).

Value

A list of class 'tradeoff_frontier' with 'frontier' (one row per combination of 'aversion' and 'env_weights') and 'current' (metrics of the current allocation). A 'plot()' method draws productivity gain against the Gini of post-support income.

Examples

fs <- farm_subsidy[1:400, ]
tf <- tradeoff_frontier(fs$farm_income, fs$fertiliser_subsidy,
                        weights = fs$weight,
                        return_rate = fs$marginal_return,
                        env_cost = fs$env_cost_per_rupee,
                        aversion = c(0, 1, 3), env_weights = c(0, 2))
tf
plot(tf)