| adapt_charging_features | R Documentation |
Calculate connection and charging times according to energy, power and time resolution
adapt_charging_features(
sessions,
time_resolution = 15,
power_resolution = 0.01
)
sessions |
tibble, sessions data set in standard format marked by |
time_resolution |
integer, time resolution (in minutes) of the sessions' datetime variables |
power_resolution |
numeric, power resolution (in kW) of the sessions' power |
All sessions' Power must be higher than 0, to avoid NaN values from dividing
by zero.
The ConnectionStartDateTime is first aligned to the desired time resolution,
and the ConnectionEndDateTime is calculated according to the ConnectionHours.
The ChargingHours is recalculated with the values of Energy and Power,
limited by ConnectionHours. Finally, the charging times are also calculated.
tibble
suppressMessages(library(dplyr))
sessions <- head(evsim::california_ev_sessions, 10)
sessions %>%
select(ConnectionStartDateTime, ConnectionEndDateTime, Power)
adapt_charging_features(
sessions,
time_resolution = 60,
power_resolution = 0.01
) %>%
select(ConnectionStartDateTime, ConnectionEndDateTime, Power)
adapt_charging_features(
sessions,
time_resolution = 15,
power_resolution = 1
) %>%
select(ConnectionStartDateTime, ConnectionEndDateTime, Power)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.