Title: | R Package for Deriving Urban Surfaces for Storm Runoff Analysis |
---|---|
Description: | Used in Project KEYS for generating inputs to runoff model ABIMO for application in cities with data scarcity. |
Authors: | Roberto Tatis-Muvdi [aut] , Michael Rustler [aut, cre] , KEYS [fnd], Kompetenzzentrum Wasser Berlin gGmbH (KWB) [cph] |
Maintainer: | Michael Rustler <[email protected]> |
License: | MIT + file LICENSE |
Version: | 0.1.0 |
Built: | 2024-11-14 03:44:55 UTC |
Source: | https://github.com/KWB-R/urbanAnnualRunoff |
The annual load is calculated with V x c. For for heavy metals -> l/m2-year x ug/l = ug/m2-year; for BOD/COD/TSS -> l/m2-year x mg/l = mg/m2-year
calculate_loads(abimo_inpout, concentrations)
calculate_loads(abimo_inpout, concentrations)
abimo_inpout |
data.frame or SpatialPolygonsDataFrame with ABIMO input and
output as retrieved by |
concentrations |
concentrations data frame as retrieved by
|
add calculated loads as additional colums to abimo_inpout data.frame or SpatialPolygonsDataFrame
read Climate Engine data and compute (source: https://app.climateengine.org/climateEngine)
computeABIMOclimate( rawdir, file_inp, file_out, summer_month_start = 4, skip = 6, sep = "", dec = "." )
computeABIMOclimate( rawdir, file_inp, file_out, summer_month_start = 4, skip = 6, sep = "", dec = "." )
rawdir |
rawdir |
file_inp |
name of input file |
file_out |
name of output file to be written in "raw_dir" |
summer_month_start |
number of month where summer half year starts (default: 4) |
skip |
skip (default: 6) |
sep |
sep (default: ”) |
dec |
dec (default: '.') |
data frame with yearly summed measurements (summer half year, total year sum) and also text file written to "raw_dir" with "out_file" name
Get ABIMO Statistics
get_abimo_stats(abimo_inpout)
get_abimo_stats(abimo_inpout)
abimo_inpout |
abimo_inpout |
tibble with columns "catchment_km2", "rainfall_cbm", "infiltration_cbm", evapotrans_cbm and "vrr" (1 - runoff_cbm / rainfall_cbm)
Get Scenario Results
get_scenario_results(paths)
get_scenario_results(paths)
paths |
paths to directory containing all ABIMO scenario results |
tibble
compute ABIMO variable FLGES (block area without street area)
makeFLGES(subcatchmSPobject)
makeFLGES(subcatchmSPobject)
subcatchmSPobject |
subcatchmSPobject |
???
spatial overlay of subcatchments and raster holding information required by ABIMO
makeOverlay( rawdir, rasterData, subcatchmSPobject, overlayName, subcatchmNamesCol )
makeOverlay( rawdir, rasterData, subcatchmSPobject, overlayName, subcatchmNamesCol )
rawdir |
Path to data directory. |
rasterData |
Name of raster file containing classified image. |
subcatchmSPobject |
Spatial dataset containing subcatchment polygons (ABIMO Blockteilflächen) (sp object type, R package sp). |
overlayName |
Name of output overlay object. |
subcatchmNamesCol |
Name of column in the attribute table of subcatchmSPobject that contains the subcatchment identifiers. This is used for naming the elements of the resulting list |
save overlay as .Rdata in directory "rawdir" with filename defined in
compute ABIMO variable PROBAU (covered sealed area)
makePROBAU(rawdir, rasterData, overlayName, targetValue)
makePROBAU(rawdir, rasterData, overlayName, targetValue)
rawdir |
rawdir |
rasterData |
rasterData |
overlayName |
overlayName |
targetValue |
targetValue |
???
compute ABIMO variable STR_FLGES (street area of block area)
makeSTR_FLGES( rawdir, subcatchmSPobject, rasterData, overlayName, targetValue, mask, add_streets_outside_subcatchments = FALSE )
makeSTR_FLGES( rawdir, subcatchmSPobject, rasterData, overlayName, targetValue, mask, add_streets_outside_subcatchments = FALSE )
rawdir |
rawdir |
subcatchmSPobject |
subcatchmSPobject |
rasterData |
rasterData |
overlayName |
overlayName |
targetValue |
targetValue |
mask |
mask |
add_streets_outside_subcatchments |
boolean (TRUE/FALSE), if TRUE: as is done for Berlin, street area outside of the subcatchment polygons is distributed among the polygons in proportion to their area. thus: street area of polygon = internal street area + allocated external street area, if FALSE: only street area within subcatchments are counted (default: FALSE) |
STR_FLGES
based on online global land use data
makeVG(rawdir, subcatchmSPobject, rasterData, targetValue)
makeVG(rawdir, subcatchmSPobject, rasterData, targetValue)
rawdir |
rawdir |
subcatchmSPobject |
subcatchmSPobject |
rasterData |
rasterData |
targetValue |
targetValue |
???
helper function: pad CODE column of ABIMO table
padCODE(string)
padCODE(string)
string |
string with CODE identifier |
padded CODE identifier (with leading "0" depending of maximium character length)
read dbf results file and joins with input shapefile
postProcessABIMO(path_input, path_output)
postProcessABIMO(path_input, path_output)
path_input |
path of ABIMO input shapefile |
path_output |
path of ABIMO output DBF file |
joined SpatialPolygonsDataFrame with ABIMO input and output
imports data from OgRe database and selects relevant substances for case study sites (Beijing, Jinxi) and calculates mean concentrations over all structures (column: "mean"). In addition new columns (short_name, unit_load, label_load) are created
read_concentrations(path)
read_concentrations(path)
path |
path to OgRe database file "annual_mean_conc.csv" |
data frame with selected substances and column
A dataset for ABIMO modelling results for Beijing case study
scenario_results_beijing
scenario_results_beijing
A data.frame with 21 rows and 20 variables:
name of scenario
sum of FLGES ans STR_FLGES (in square kilometers)
total rianfall in catchment ABIMO (in cubicmeters/year)
calculated runoff by ABIMO (in cubicmeter)
calculated infiltration by ABIMO (in cubicmeter/year)
calculated evapotranspiration by ABIMO (in cubicmeter/year)
calculated volume rainfall retained (1-runoff_cbm/rainfall_cbm)
tibble with ABIMO input/output (only water balance)
tibble with ABIMO input/output (water balance + emissions)
Biological Oxygen Demand (in kg/year)
Chemical Oxygen Demand (in kg/year)
Total Supended Solid (in kg/year)
Lead (in kg/year)
Cadmium (in kg/year)
Chrome (in kg/year)
Copper (in kg/year)
Nickel (in kg/year)
Vanadium (in kg/year)
Zinc (in kg/year)
A dataset for ABIMO modelling results for Jinxi case study
scenario_results_jinxi
scenario_results_jinxi
A data.frame with 3 rows and 20 variables:
name of scenario
sum of FLGES ans STR_FLGES (in square kilometers)
total rianfall in catchment ABIMO (in cubicmeters/year)
calculated runoff by ABIMO (in cubicmeter)
calculated infiltration by ABIMO (in cubicmeter/year)
calculated evapotranspiration by ABIMO (in cubicmeter/year)
calculated volume rainfall retained (1-runoff_cbm/rainfall_cbm)
tibble with ABIMO input/output (only water balance)
tibble with ABIMO input/output (water balance + emissions)
Biological Oxygen Demand (in kg/year)
Chemical Oxygen Demand (in kg/year)
Total Supended Solid (in kg/year)
Lead (in kg/year)
Cadmium (in kg/year)
Chrome (in kg/year)
Copper (in kg/year)
Nickel (in kg/year)
Vanadium (in kg/year)
Zinc (in kg/year)