Nothing
Is collaboration load reducing personal time?
if(sum(my_sq_data$Work_time, na.rm = TRUE) == 0){ KPI_1 <- "0 " } else { KPI_1 <- my_sq_data %>% create_bar(metric = "Work_time", hrvar = NULL, return = "table") %>% select(Work_time) %>% pull(1) %>% round(1) } paste(KPI_1, "hr work days") %>% flexdashboard::valueBox(icon = "fa-calendar", color = "#34b1e2")
if(sum(my_sq_data$Work_time, na.rm = TRUE) == 0){ md2html("## Note: there is insufficient urgent collaboration data to display.") } else { balance1_w1_plot1 <- my_sq_data %>% mutate(Personal_time = 16 - Work_time) %>% create_stacked(metric = c("Work_time", "Personal_time"), hrvar = hrvar, rank = NULL) + labs(title = "Employee workday", subtitle = "Average hours per person per day") balance1_w1_plot1 }
KPI_2 <- my_sq_data %>% create_bar(metric = "dailyCollabHours", hrvar = NULL, return = "table") %>% select(dailyCollabHours) %>% pull(1) %>% round(1) paste(KPI_2, "hrs in collaboration") %>% flexdashboard::valueBox(icon = "fa-user-friends", color = "#00508F")
balance1_w2_plot1 <- my_sq_data %>% rename(`Collaboration Hours` = "dailyCollabHours") %>% create_bar(metric = "Collaboration Hours", hrvar = hrvar, bar_colour = "#00508F", rank = NULL) balance1_w2_plot1 + labs(title = "Collaboration hours", subtitle= "Average hours per person per day")
KPI_3 <- my_sq_data %>% create_dist(metric="dailyCollabHours", hrvar=NULL, cut = c(3, 6), return="table") if(!("6+ hours" %in% names(KPI_3))){ KPI_3 <- 0 } else { KPI_3 <- KPI_3 %>% select("6+ hours") %>% pull(1) %>% round(2) } paste(KPI_3 * 100, "% over-collaborators") %>% flexdashboard::valueBox(icon = "fa-thermometer-full", color = "#f59b76")
balance1_w3_plot1 <- my_sq_data %>% create_dist(metric="dailyCollabHours", hrvar=hrvar, cut = c(3, 6), unit = "hours", dist_colours = c("#f59b76", "#fcf0eb", "#bfe5ee")) balance1_w3_plot1 <- balance1_w3_plot1 + labs(title = "Collaboration distribution", subtitle ="% of employees by daily collaboration") balance1_w3_plot1
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.