View source: R/summary_emission.R
summary_emission | R Documentation |
Calculate the summary for each specie of gas and aerosol in a given emission file
summary_emission(
file = file.choose(),
chem_opt = "cb05",
remove_zeros = TRUE,
remove_dim = TRUE,
pm = FALSE,
voc = FALSE,
mask = NULL,
verbose = F
)
file |
file patch and name |
chem_opt |
chemical mechanism option, default is CB05 |
remove_zeros |
remove empty values (all zeros) from table, default is TRUE |
remove_dim |
remove dimension variables XLAT, XLON and Times from table,default is TRUE |
pm |
calculate total PM, default is FALSE |
voc |
calculate total voc, nox and nox/voc ratio and nox/voc ratio in propylene-eq |
mask |
sf object MULTIPOLYGON from a shapefile, see notes and example |
verbose |
display additional information |
a data.frame containing the pollutant name, minimum, average, maximum, units, molar weight and total (in kt/year)
Molar mass for PAR is estimated considering weighted average of: Propane 11%, Butanes 18%, Pentanes 9%, Hexanes and higher alkanes 39%, Acetylene 5%, Benzene 11%, Esters 3%, Ethers 4%) divided by the number of carbons (1.5 for propane, 4 for Butanes, 5 for pentanes, 5.86 for Hexanes and 1 for the others).
If the mask argument is provided, only the inner region of the shapefile is used to determine the total emissions.
# sample shapefile for Brazil and Brazilian regions
BR <- sf::read_sf(paste0(system.file("extdata",package="hackWRF"),"/BR.shp"))
BR_regions <- sf::read_sf(paste0(system.file("extdata",package="hackWRF"),"/BR_regions.shp"))
## Not run:
file <- file.choose()
# fast check for the entire file
summary_emission(file = file)
# check using the BR
summary_emission(file = file,mask = BR)
# check using the midwest region from BR_regions
midwest <- BR_regions[2,]
summary_emission(file = file,mask = midwest)
# opening map for Metropolitan area of Sao Paulo
masp <- sf::read_sf(paste0(system.file("extdata",package="hackWRF"),"/RMSP.shp"))
# comnining the citis into a mask
masp <- sf::st_combine(sf::st_union(masp))
summary_emission(file = file,mask = masp)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.