Get the clinical theatre emissions after a data frame is inputted into the function.
clinical_theatre_data(
data,
time,
date_format = c("%d/%m/%Y"),
name,
wet_clinical_waste = 0,
wet_clinical_waste_unit = c("tonnes", "kg"),
desflurane = 0,
sevoflurane = 0,
isoflurane = 0,
methoxyflurane = 0,
N2O = 0,
propofol = 0,
water_supply = 0,
water_trt = TRUE,
water_unit = c("cubic metres", "million litres"),
electricity_kWh = 0,
electricity_TD = TRUE,
electricity_WTT = TRUE,
heat_kWh = 0,
heat_TD = TRUE,
heat_WTT = TRUE,
glass = 0,
board = 0,
mixed = 0,
paper = 0,
average = 0,
average_film = 0,
average_rigid = 0,
HDPE = 0,
LDPE = 0,
LLDPE = 0,
PET = 0,
PP = 0,
PS = 0,
PVC = 0,
glass_WD = 0,
glass_waste_disposal = c("Closed-loop", "Combustion", "Landfill", "Open-loop"),
board_WD = 0,
mixed_WD = 0,
paper_WD = 0,
paper_waste_disposal = c("Closed-loop", "Combustion", "Composting", "Landfill"),
average_WD = 0,
average_film_WD = 0,
average_rigid_WD = 0,
HDPE_WD = 0,
LDPE_WD = 0,
LLDPE_WD = 0,
PET_WD = 0,
PP_WD = 0,
PS_WD = 0,
PVC_WD = 0,
plastic_waste_disposal = c("Closed-loop", "Combustion", "Landfill", "Open-loop"),
fridges = 0,
freezers = 0,
electric_waste_disposal = c("Landfill", "Open-loop"),
glass_units = c("kg", "tonnes"),
paper_units = c("kg", "tonnes"),
plastic_units = c("kg", "tonnes"),
electrical_units = c("kg", "tonnes"),
include_cpi = FALSE,
jurisdiction = NULL,
year = NULL,
period = 0,
manual_price = NULL,
gti_by = c("default", "month", "year"),
overall_by = c("default", "month", "year"),
single_sheet = FALSE
)
Returns list containing two objects. A table containing CO2e emissions for each row of data (and carbon price index in USD if include_cpi
is TRUE
), and a ggplot2
object plotting the CO2e emissions. The second object is a single sheet containing summaries if single_sheet = TRUE
.
Data frame containing all data to be used in the emissions calculation
Variable in data
that corresponds to the time.
The date format for the time variable (optional, default: c("%d/%m/%Y")).
Variable in data
that corresponds to the theatre name.
Amount of (wet) clinical waste that is usually incinerated.
Unit for wet_clinical_waste
variable. Options are "tonnes"
or "kg"
.
Amount of desflurane used in KG (default: 0).
Amount of sevoflurane used in KG (default: 0).
Amount of isoflurane used in KG (default: 0).
Amount of methoxyflurane used in KG (default: 0).
Amount of nitrous oxide (N2O) used in KG (default: 0).
Amount of propofol used in KG (default: 0).
Amount of water used in the building.
logical. Default TRUE
. Whether to include emissions associated with water treatment for used water.
Unit for water_supply
variable. Options are "cubic metres"
or "million litres"
.
Electricity used in kWh.
logical. Default TRUE
. Whether to include emissions associated with grid losses.
logical. Default TRUE
. Whether to include emissions associated with extracting, refining, and transporting fuels.
heat and steam used in kWh.
logical. Default TRUE
. Whether to include emissions associated with grid losses.
logical. Default TRUE
. Whether to include emissions associated with extracting, refining, and transporting fuels.
Numeric value representing the amount of glass. Default is 0
.
Numeric value indicating the weight of paperboard. Default is 0
.
Numeric value indicating the weight of mixed paper. Default is 0
.
Numeric value indicating the weight of paper. Default is 0
.
Numeric value indicating the weight of average plastic. Default is 0
.
Numeric value indicating the weight of average film plastic. Default is 0
.
Numeric value indicating the weight of average rigid plastic. Default is 0
.
Numeric value indicating the weight of HDPE plastic. Default is 0
.
Numeric value indicating the weight of LDPE plastic. Default is 0
.
Numeric value indicating the weight of LLDPE plastic. Default is 0
.
Numeric value indicating the weight of PET plastic. Default is 0
.
Numeric value indicating the weight of PP plastic. Default is 0
.
Numeric value indicating the weight of PS plastic. Default is 0
.
Numeric value indicating the weight of PVC plastic. Default is 0
.
Numeric value representing the amount of glass waste with disposal. Default is 0
.
Character vector specifying the waste disposal method to use for metal for calculating emissions. Possible values: "Closed-loop"
, "Combustion"
, "Landfill"
, "Open-loop"
. Default is "Closed-loop". See details
for more information.
Numeric value indicating the weight of paperboard disposed of using waste disposal methods. Default is 0
.
Numeric value indicating the weight of mixed paper disposed of using waste disposal methods. Default is 0
.
Numeric value indicating the weight of paper disposed of using waste disposal methods. Default is 0
.
Character vector specifying the waste disposal method for paper to use for calculating emissions. Possible values: "Closed-loop"
, "Combustion"
, "Composting"
, "Landfill"
. Default is "Closed-loop"
. See details
for more information.
Numeric value indicating the weight of average plastic disposed of using waste disposal methods. Default is 0
.
Numeric value indicating the weight of average film plastic disposed of using waste disposal methods. Default is 0
.
Numeric value indicating the weight of average rigid plastic disposed of using waste disposal methods. Default is 0
.
Numeric value indicating the weight of HDPE plastic disposed of using waste disposal methods. Default is 0
.
Numeric value indicating the weight of LDPE plastic disposed of using waste disposal methods. Default is 0
.
Numeric value indicating the weight of LLDPE plastic disposed of using waste disposal methods. Default is 0
.
Numeric value indicating the weight of PET plastic disposed of using waste disposal methods. Default is 0
.
Numeric value indicating the weight of PP plastic disposed of using waste disposal methods. Default is 0
.
Numeric value indicating the weight of PS plastic disposed of using waste disposal methods. Default is 0
.
Numeric value indicating the weight of PVC plastic disposed of using waste disposal methods. Default is 0
.
Character vector specifying the waste disposal method for plastic to use for calculating emissions. Possible values: "Closed-loop"
, "Combustion"
, "Landfill"
, "Open-loop"
. Default is "Closed-loop"
. See details
for more information.
Numeric value indicating the weight of fridges. Default is 0
.
Numeric value indicating the weight of freezers. Default is 0
.
Character vector specifying the waste disposal method for electrical items to use for calculating emissions. Possible values: "Landfill"
, "Open-loop"
. Default is "Landfill"
. See details
for more information.
Character vector specifying the units of the emissions related to glass. Possible values: "kg"
, "tonnes"
. Default is "kg"
.
Character vector specifying the units of the emissions related to paper. Possible values: "kg"
, "tonnes"
. Default is "kg"
.
Character vector specifying the units of the emissions related to plastic materials. Possible values: "kg"
, "tonnes"
. Default is "kg"
.
Character vector specifying the units of the emissions related to electrical materials. Possible values: "kg"
, "tonnes"
. Default is "kg"
.
Logical variable specifying whether to calculate carbon price credit as well as emissions.
A character string specifying the jurisdiction for which the carbon price credit should be calculated. Available jurisdictions can be found by check_CPI()
.
An optional numeric value specifying the year for which the carbon price credit should be calculated.
If NULL
, the most recent year available in the CPI data will be used.
An optional numeric value specifying the period within the specified year for which the carbon price credit should be calculated.
If 1
, the function will use the first period if it is available; if 2
, the function will use the second period if it is available. If 0
, the function will calculate the mean between the first and second period.
An option to manually input a carbon price index to override the value in the World Bank Data.
The grouping type for calculating the GTI ("default", "month", "year").
The grouping type for the total output plot ("default", "month", "year"). This is a plot of the emissions if include_cpi = FALSE
, otherwise is the CPI value.
Options are NULL
, TRUE
or FALSE
. This is whether to give the summaries in a single sheet display, or as a list containing the table and ggplot2
objects.
If NULL
then no graphical output is given.
# \donttest{
# Example with dummy data
df <- data.frame(time = c("10/04/2000", "10/04/2000", "11/04/2000",
"11/04/2000", "12/04/2000", "12/04/2000"),
theatre = rep(c("A", "B"), times = 3),
clinical_waste = c(80, 90, 80, 100, 120, 110),
electricity_kwh = c(100, 110, 90, 100, 100, 110),
general_waste = c(65, 55, 70, 50, 60, 30))
clinical_theatre_data(df, time = time, name = theatre,
wet_clinical_waste = clinical_waste,
wet_clinical_waste_unit = "kg",
desflurane = 10,
average = general_waste,
plastic_units = "kg",
electricity_kWh = electricity_kwh,
include_cpi = TRUE,
jurisdiction = "Australia",
year = 2023,
single_sheet = FALSE)
# }
Run the code above in your browser using DataLab