"0","# first need transfer_to_EOL reshaped"
"0","transfer_to_EOL <- gather(transfer_to_EOL, `CarbonImpact`, `EnergyImpact` , key = ""impact_type"", value = ""impact_value"") %>%"
"0","   add_column(impact_units = c(rep(""kg CO2e"", 4), rep(""MJ"", 4)))"
"0","demo_transport <- filter(demo, material_impacts != 0) %>%"
"0","   rename(impact_units = material_impact_units) %>%"
"0","   mutate(site_transport_impact = case_when("
"0","      impact_units == ""kg CO2e"" ~ quantity * as.numeric(routes[3,9]),"
"0","      impact_units == ""MJ"" ~ quantity * as.numeric(routes[3,10]))) %>%"
"0","   left_join(transfer_to_EOL, by = c(""SimpleEOLname"", ""impact_units"") ) %>%"
"0","   mutate(EOL_transport_impact = quantity * impact_value) %>%"
"0","   select(""house_age"", ""house_size"", ""project"", ""contractor"", ""deconMaterialName"", ""SimpleEOLname"", ""disposition"", ""quantity"", ""quantity_units"", ""material_impacts"", ""site_transport_impact"", ""EOL_transport_impact"", ""impact_units"")"
"0","      "
"0","# save this file for the final net benefits calculation and for exploratory graphics"
"0","write.csv(demo_transport, ""intermediary/final_demolition_scenario_with_transport.csv"")"
