Title: | Toolkit for Data Analytics in Human Resources |
---|---|
Description: | Transform and analyze workforce data in meaningful ways for human resources (HR) analytics. Get started with workforce planning using a simple Shiny app. |
Authors: | Dale Kube [aut, cre] |
Maintainer: | Dale Kube <[email protected]> |
License: | GPL |
Version: | 0.2.5 |
Built: | 2025-03-01 06:23:01 UTC |
Source: | https://github.com/dalekube/hr |
The hierarchy function transforms a standard set of unique employee and supervisor identifiers (employee IDs, email addresses, etc.) into a wide or elongated format that can be used to aggregate employee data by a particular line of leadership (i.e. include everyone who rolls up to Susan).
hierarchy(ee, supv, format = "long", descending = TRUE)
hierarchy(ee, supv, format = "long", descending = TRUE)
ee |
A vector containing unique identifiers for employees. |
supv |
A vector containing unique identifiers for supervisors. These values should be of the same type as the employee values. |
format |
character string; either "long" or "wide"; default = "long". |
descending |
logical; default = TRUE. Should the hierarchy levels be descending (i.e. the top person in the hierarchy is represented at level 1)? |
data table
ee = c("[email protected]","[email protected]","[email protected]","[email protected]") supv = c("[email protected]","[email protected]","[email protected]","[email protected]") hierarchy(ee,supv,format="long",descending=TRUE)
ee = c("[email protected]","[email protected]","[email protected]","[email protected]") supv = c("[email protected]","[email protected]","[email protected]","[email protected]") hierarchy(ee,supv,format="long",descending=TRUE)
The hierarchyStats function computes summary statistics and span of control metrics from a standard set of unique employee and supervisor identifiers (employee IDs, email addresses, etc.).
hierarchyStats(ee, supv)
hierarchyStats(ee, supv)
ee |
A vector containing unique identifiers for employees. |
supv |
A vector containing unique identifiers for supervisors. These values should be of the same type as the employee values. |
list
ee = c("[email protected]","[email protected]","[email protected]","[email protected]") supv = c("[email protected]","[email protected]","[email protected]","[email protected]") hierarchyStats(ee,supv)
ee = c("[email protected]","[email protected]","[email protected]","[email protected]") supv = c("[email protected]","[email protected]","[email protected]","[email protected]") hierarchyStats(ee,supv)
The hierarchyValid function considers a standard set of unique employee and supervisor identifiers (employee IDs, email addresses, etc.) and validates the completeness and quality of the two input vectors representing the overall hierarchy.
hierarchyValid(ee, supv)
hierarchyValid(ee, supv)
ee |
A vector containing unique identifiers for employees. |
supv |
A vector containing unique identifiers for supervisors. These values should be of the same type as the employee values. |
logical
ee = c("[email protected]","[email protected]","[email protected]","[email protected]") supv = c("[email protected]","[email protected]","[email protected]","[email protected]") hierarchyValid(ee,supv)
ee = c("[email protected]","[email protected]","[email protected]","[email protected]") supv = c("[email protected]","[email protected]","[email protected]","[email protected]") hierarchyValid(ee,supv)
Artificial data that reflects the workforce history data structure often used to manage employment records in a human capital management system (HCM). Modern enterprises store data in this format at the core of their HCM. This data is the root source of all data analysis and reporting related to headcount, hiring, turnover, etc.
data(workforceHistory)
data(workforceHistory)
A data table with 45 rows and 10 variables:
Effective date of the record
Effective sequence of the record (used to manage multiple records for the same effective date)
Action
Employee ID
Supervisor ID
Employee type (employee or contractor)
Regular, temporary, or contract employment
Job title
Employment status
Employee name
...
Launch a simple, interactive workforce planning worksheet that helps managers and team leaders to execute basic workforce planning tasks and plan ahead for hiring, turnover, and other factors that influence a team's talent structure. Data analysts can use this alongside team leaders to convey change and proactively think about recruitment, etc.
workforcePlan(launch.browser = T)
workforcePlan(launch.browser = T)
launch.browser |
Logical; whether the app should launch in the user's default browser |