View source: R/flag_ch_ratio.R
| flag_ch_ratio | R Documentation |
This function flags persons who have an unusual ratio of collaboration hours to after-hours collaboration hours. Returns a character string by default.
flag_ch_ratio(data, threshold = c(1, 30), return = "message")
data |
A data frame containing a Person Query. |
threshold |
Numeric value specifying the threshold for flagging. Defaults to 30. |
return |
String to specify what to return. Options include:
|
A different output is returned depending on the value passed to the return
argument:
"message": message in the console containing diagnostic summary
"text": string containing diagnotic summary
"data": data frame. Person-level data with flags on unusually high or
low ratios
The metric Collaboration_hours is used in the calculations. Please ensure
that your query contains a metric with the exact same name.
Other Data Validation:
check_query(),
extract_hr(),
flag_em_ratio(),
flag_extreme(),
flag_outlooktime(),
hr_trend(),
hrvar_count(),
hrvar_count_all(),
hrvar_trend(),
identify_churn(),
identify_holidayweeks(),
identify_inactiveweeks(),
identify_nkw(),
identify_outlier(),
identify_privacythreshold(),
identify_query(),
identify_shifts(),
identify_shifts_wp(),
identify_tenure(),
remove_outliers(),
standardise_pq(),
subject_validate(),
subject_validate_report(),
track_HR_change(),
validation_report()
flag_ch_ratio(sq_data)
data.frame(PersonId = c("Alice", "Bob"),
Collaboration_hours = c(30, 0.5),
After_hours_collaboration_hours = c(0.5, 30)) %>%
flag_ch_ratio()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.