зеркало из https://github.com/microsoft/wpa.git
feat: add exp_hours argument
This commit is contained in:
Родитель
567d1c7a8f
Коммит
d300ac5a7c
|
@ -13,6 +13,8 @@
|
|||
#' @param signals See `workpatterns_classify()`.
|
||||
#' @param start_hour See `workpatterns_classify()`.
|
||||
#' @param end_hour See `workpatterns_classify()`.
|
||||
#' @param exp_hours See `workpatterns_classify()`.
|
||||
#'
|
||||
#' @param path Pass the file path and the desired file name, _excluding the file
|
||||
#' extension_. For example, `"scope report"`.
|
||||
#' @param timestamp Logical vector specifying whether to include a timestamp in
|
||||
|
@ -32,6 +34,7 @@ workpatterns_report <- function(data,
|
|||
signals = c("email", "IM"),
|
||||
start_hour = "0900",
|
||||
end_hour = "1700",
|
||||
exp_hours = NULL,
|
||||
path = "workpatterns report",
|
||||
timestamp = TRUE){
|
||||
|
||||
|
@ -52,6 +55,7 @@ workpatterns_report <- function(data,
|
|||
signals = signals,
|
||||
start_hour = start_hour,
|
||||
end_hour = end_hour,
|
||||
exp_hours = exp_hours,
|
||||
return = "list")
|
||||
|
||||
## plot for `workpatterns_rank`
|
||||
|
@ -135,7 +139,7 @@ workpatterns_report <- function(data,
|
|||
plot_rank_list[[7]],
|
||||
plot_rank_list[[8]]
|
||||
) %>% # Expand objects to this list
|
||||
purrr::map_if(is.data.frame, wpa::create_dt, rounding = 2) %>%
|
||||
purrr::map_if(is.data.frame, wpa::create_dt, rounding = 1, percent = TRUE) %>%
|
||||
purrr::map_if(is.character, md2html)
|
||||
|
||||
## Set header titles
|
||||
|
|
|
@ -10,6 +10,7 @@ workpatterns_report(
|
|||
signals = c("email", "IM"),
|
||||
start_hour = "0900",
|
||||
end_hour = "1700",
|
||||
exp_hours = NULL,
|
||||
path = "workpatterns report",
|
||||
timestamp = TRUE
|
||||
)
|
||||
|
@ -26,6 +27,8 @@ workpatterns_report(
|
|||
|
||||
\item{end_hour}{See \code{workpatterns_classify()}.}
|
||||
|
||||
\item{exp_hours}{See \code{workpatterns_classify()}.}
|
||||
|
||||
\item{path}{Pass the file path and the desired file name, \emph{excluding the file
|
||||
extension}. For example, \code{"scope report"}.}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче