blockbuster: The deterioration of a 'blockbuster_tibble' through time.

Description Usage Arguments Value Examples

View source: R/blockbuster.R

Description

High level modelling of a blockbuster_tibble through time that considers repairs and rebuilding interventions on the condition of the modelled building components. It is composed of many smaller functions that deteriorate, rebuild and repair the blockbuster_tibble. Outputs a list of blockbuster_tibbles with each tibble containing the unit_area and condition of the element sub_element constr_type combination at a given timestep while also duplicating all other variables and values from the input tibble. This is not as expensive as it sounds because modifying a list no longer makes a deep copy; modifying a list efficiently reuses existing vectors (R >= 3.1.0). After each timestep is simulated the unit_area are aggregated by identifying features, e.g. buildingid, elementid and grade. Then repair cost estimates are calculated using blockcoster_lookup to find the correct constant which is multiplied by the unit_area to give the expected repair cost (the initial unit_area at time zero is estimated using areafy2). Grade E building components have a repair cost of 5 per cent on Grade D, see blockbuster_pds_repair_costs for repair cost details. A seperate variable block_rebuild_cost is created to help quantify Grade E cost. This cost value applies to the estimated rebuild cost of the whole block (not just that one building component) based on the argument rebuild_cost_rate (<c2><a3> per m^2). For the moment we simplify by adding a costing for E grade to the blockcoster_lookup, this simply takes the D grade costing and adds 5 per cent to it (based on expert domain knowledge of @adam.bray@education.gov.uk).

Usage

1
2
blockbuster(blockbuster_tibble, forecast_horizon, rebuild_monies = 0,
  repair_monies = 0, rebuild_cost_rate = 1274)

Arguments

blockbuster_tibble

a blockbuster dataframe or tibble.

forecast_horizon

an integer for the number of timesteps to model deterioration over.

rebuild_monies

a numeric vector of length equal to the forecast_horizon or one.

repair_monies

a numeric vector of length equal to the forecast_horizon or one.

rebuild_cost_rate

a numeric vector of length equal to the forecast_horizon or one.

Value

An object of class blockbuster_list; list of n plus one tibbles (where n is the forecast_horizon). The first tibble is the initial blockbuster_tibble.

Examples

1
2
two_yrs_counterfactual <- blockbuster(dplyr::filter(blockbuster_pds,
 buildingid == 127617), 2)

DFE-Capital/blockbuster documentation built on May 26, 2019, 7:23 a.m.