For the evaluation of tickets processed by a help desk I would like to know how many business hours an ticket is active. I can easily subtract the times and get the total amount
I ran into similar needs recently and created a package based on @mvan 's script above.
https://github.com/janzzon/difftimeOffice
Input needs to be as POSIX time.
Output is in seconds.
Specify helpdesk open hours by argument working_hours = c(8.5, 18)
.
Additional holliday days is not implemented (yet).