This package creates time blocks out of serial data and calculates adherences based on pthe proprortion of days covered methods
#Install package from github
library(devtools)
install_github('smm52/timeBlocks')
library(timeBlocks)
If the package was still loaded you might have to call the following line before loading the library
detach("package:timeBlocks", unload=TRUE)