Your HR team manages hundreds of employees but may treat them as one group: same engagement program, same retention strategy, same career path. A workforce may or may not form clear groups. This analysis looks for groups in your HRIS data so you can check whether separate programs would help, instead of guessing.
Worked Example: Can Two Scores Form Groups? (Made-Up Data)
Question: Can a tenure score and a satisfaction score form groups in made-up staff data?
Inputs: Simulated data, seed 17. The script makes 24 fictional staff rows, each with two scores scaled from 0 to 1: a tenure score and a satisfaction score. These are scores, not years.
What is built in: Three groups of eight rows, with centers (tenure score, satisfaction score) of (0.25, 0.75), (0.75, 0.35) and (0.55, 0.70), and noise with SD 0.07, clipped to the 0 to 1 range. The groups exist by construction. The k-means start rows (1, 9 and 17) are the first row of each built group, a favorable start that a real analyst cannot know.
Method: K-means makes 3 groups by moving each group mean until the groups stop changing.
import numpy as np
# Simulated data, seed 17. Each row is one fictional employee.
rng = np.random.default_rng(17)
centers = np.array([
[0.25, 0.75], # short tenure, higher satisfaction
[0.75, 0.35], # longer tenure, lower satisfaction
[0.55, 0.70], # mid tenure, higher satisfaction
])
rows = np.vstack([c + rng.normal(0, 0.07, size=(8, 2)) for c in centers])
rows = np.clip(rows, 0, 1)
# K-means with three starting rows; values are already on a 0 to 1 scale.
k = 3
means = rows[[0, 8, 16]].copy()
for _ in range(100):
d = ((rows[:, None, :] - means[None, :, :]) ** 2).sum(axis=2)
labels = d.argmin(axis=1)
new_means = np.array([rows[labels == i].mean(axis=0) for i in range(k)])
if np.allclose(means, new_means):
break
means = new_means
print("Simulated data, seed 17")
print("Question: Can tenure and satisfaction form useful groups in a small example?")
print("Inputs: 24 fictional employees; tenure and satisfaction scores, 0 to 1.")
print("Method: k-means with 3 groups, starting from rows 1, 9, and 17.")
for i in range(k):
g = rows[labels == i]
print(f"Group {i + 1}: count={len(g)}, mean_tenure={g[:, 0].mean():.2f}, "
f"mean_satisfaction={g[:, 1].mean():.2f}")
print("Limit: These simulated groups do not show that real staff form "
"stable or useful segments.")
Output:
Simulated data, seed 17
Question: Can tenure and satisfaction form useful groups in a small example?
Inputs: 24 fictional employees; tenure and satisfaction scores, 0 to 1.
Method: k-means with 3 groups, starting from rows 1, 9, and 17.
Group 1: count=8, mean_tenure=0.20, mean_satisfaction=0.75
Group 2: count=7, mean_tenure=0.74, mean_satisfaction=0.34
Group 3: count=9, mean_tenure=0.55, mean_satisfaction=0.65
Limit: These simulated groups do not show that real staff form stable or useful segments.
Result: The run gives groups of 8, 7 and 9 rows. Their mean (tenure score, satisfaction score) values are (0.20, 0.75), (0.74, 0.34) and (0.55, 0.65), close to the built-in centers. One row moved: a row built into the second group landed in the third, giving counts of 8, 7 and 9 instead of 8, 8 and 8. The second and third centers are close, so a row near the boundary can fall on either side.
Limit: The groups were built in and the start rows were chosen to suit them, so recovering them is expected. Made-up rows cannot show that real staff form stable or useful groups.
What Is Workforce Segmentation?
Workforce segmentation uses clustering algorithms to group employees by similarity, not by department or job title, but by patterns in their tenure, satisfaction, compensation, performance, and demographics combined. It can surface groups that HR hasn't thought to look for.
Labels an analyst might look for (these are possible labels, not findings):
- Flight-risk stars: high performance, low satisfaction, under-compensated relative to peers. A pay rise may be one possible reason to leave; check that against your own pay and exit data.
- Comfortable coasters: long tenure, adequate performance, high satisfaction, zero growth trajectory. Not a problem until they block promotions below them.
- Enthusiastic newcomers: short tenure, high engagement, rapidly developing. Need mentorship and challenge, not generic onboarding.
- Burned-out contributors: high overtime, declining satisfaction, still productive but deteriorating.
You probably have names for some of these intuitively. The model tells you who is in each group, how many, and what makes them different, with data, not hunches. Whether the groups mean anything is a question for your own data and judgment.
When to Use Workforce Segmentation
This analysis suits teams with an HRIS export that has several numeric columns per employee and a question that groups could help answer.
- Designing targeted retention programs: different groups may need different interventions
- Identifying hidden workforce risks: clusters can show patterns that standard HR dashboards miss
- Rationalizing compensation: look at which groups are under-compensated relative to their performance
- Board and leadership reporting: a short table of groups with counts and average scores
- After a reorg or acquisition: see how the combined workforce clusters before designing new programs
What Data Do You Need?
A CSV export from your HRIS combining demographics, compensation, performance, and satisfaction. Depending on your system (BambooHR, Workday, ADP, SAP SuccessFactors), you may need to merge a few custom reports.
Required columns
- Employee ID: any unique identifier
- Age, or birth year
- Years at company, or hire date
- Monthly income, or annual salary
- Performance rating: most recent cycle
- Job satisfaction: survey score (1-4 or 1-5)
Columns that can add detail to segmentation
- Years in current role: captures stagnation
- Years since last promotion: career velocity signal
- Work-life balance score: burnout indicator
- Overtime hours or flag: workload signal
- Training hours last year: investment signal
- Distance from home: commute burden
- Department: for characterizing clusters (not used as clustering input)
Numeric columns are standardized to a common scale before clustering, so income in dollars does not drown out a satisfaction score.
How to Read the Report
Elbow chart: shows how fit changes as you add clusters. The "elbow" where adding more clusters stops improving fit is one guide to how many groups to use. Choose a group count for the data at hand, then check whether the groups help answer a real HR question.
Silhouette scores: measure how well-separated the clusters are. Higher values mean tighter, more separate groups. If the groups overlap a lot, try adding input variables or removing highly correlated ones.
Cluster profile radar charts: each cluster gets a radar chart showing its average on every dimension. You can see at a glance which cluster is "high income, low satisfaction, long tenure" versus "low income, high satisfaction, short tenure."
PCA scatter plot: shows all employees in 2D space, colored by cluster. A plot can help you inspect cluster shape. Treat it as an exploratory view, then check the groups in the source data and ask whether they have a useful meaning for HR. Overlapping blobs suggest the data may not support distinct clustering.
Cluster characterization table: a cluster table can list each group's count and the mean values for the inputs, as in the simulated example above.
What to Do With the Results
Immediate
- Name each segment: give them memorable labels so leadership can discuss them
- Cross-reference with attrition data: which segments have the highest actual turnover? Does it match the risk profile?
- Flag high-value at-risk segments: for example, a cluster of senior engineers with below-median satisfaction
Strategic
- Design segment-specific retention programs: career acceleration for flight-risk stars, workload reduction for burned-out contributors, challenge assignments for enthusiastic newcomers
- Run quarterly: employees move between segments. Track migration patterns to catch deterioration early.
- Check the groups on separate data: you can report differences in satisfaction or performance as descriptive results. Since those measures may have helped form the groups, do not use a one-way ANOVA on them alone as proof that the groups are real. Check the pattern on separate data or on measures not used to make the groups.
When to Use Something Else
- Want to predict who will leave: Use attrition prediction, it gives individual risk scores, not group membership.
- Want to compare two specific groups: Use a t-test (e.g., male vs female salary) or ANOVA (three or more departments).
- Want to understand survey results: Use survey categorical analysis for response patterns.
- Very small teams: Manual segmentation by tenure bands and performance quartiles may be more practical than clustering.
Your turn
Bring your own data and the question you actually need answered.
MCP AnalyticsData science by email Send us your data and your question, and we will reply. ds@mcpanalytics.ai