powered by
A function that calculates CO2e emissions between ferry ports.
ferry_emissions( from, to, via = NULL, type = c("Foot", "Car", "Average"), num_people = 1, times_journey = 1, include_WTT = TRUE, round_trip = FALSE )
Returns CO2e emissions in tonnes for the ferry journey.
Port code for the port departing from. Use seaport_finder to find port code.
seaport_finder
Port code for the port arriving from. Use seaport_finder to find port code.
Optional. Takes a vector containing the port code that the ferry travels through. Use seaport_finder to find port code.
Whether the journey is taken on foot or by car. Options are "Foot", "Car", "Average".
"Foot"
"Car"
"Average"
Number of people taking the journey. Takes a single numerical value.
Number of times the journey is taken.
logical. Recommended TRUE. Whether to include emissions associated with extracting, refining, and transporting fuels.
TRUE
Whether the journey is one-way or return.
The distances are calculated using the Haversine formula. This is calculated as the crow flies.
# Emissions for a ferry journey between Belfast and New York City seaport_finder(city = "Belfast") seaport_finder(city = "New York") ferry_emissions(from = "BEL", to = "BOY")
Run the code above in your browser using DataLab