Skip to contents

Calculate average annual damage (AAD) by integrating flood damages over scenario probabilities and flood event weights for each state and stake.

Usage

format_aad(x, state = NULL)

Arguments

x

An object of class Sector or Case.

state

Optional character or numeric vector of state identifiers to filter the results. If NULL (default), all states are included.

Value

If x is a Sector: a numeric matrix of AAD with states as rows and stakes (including "total") as columns. If x is a Case: a named list of such matrices for each sector, plus a "global" entry.

Details

The calculation proceeds through three steps:

  1. Direct damages from format_sector() are multiplied by their scenario probabilities.

  2. Damages are aggregated across flood scenarios for each state.

  3. Numerical integration across flood events is performed using the trapezoidal weights obtained from format_flood().

For a multi-sector Case, calculations are carried out per sector and summed to create a "global" entry. If state is provided, the output is subsetted to the specified states.

Author

Frédéric Grelot, frederic.grelot.1994_cran@m4x.org