How Data Science Is Used in Gaming
A small puzzle-game studio creates two tutorials. Several testers finish quickly; others retry repeatedly or leave before the final checkpoint. Should the designers replace the longer version? Does more time mean more fun? Would a completed tutorial prove that someone returns tomorrow? These questions require carefully defined measurements, not guesses about enjoyment.
Data science in gaming analyzes gameplay information to investigate progression, difficulty, performance, personalization and player experience. It can identify patterns for review, but a metric cannot independently prove that a game is entertaining, fair, safe or accessible.
This updated Notes for SHS guide retains useful earlier lessons on player behavior, recommendations, monetization, development testing, cheat detection, multiplayer systems and NPCs. It adds a complete fictional twelve-session puzzle-game comparison, charts, formulas and optional Python. Students need no commercial game, private player information or professional studio account.
What you’ll learn: Explain telemetry and ten game-analytics applications, calculate completion and checkpoint rates, create a progression funnel, compare retries and time, distinguish retention from completion, and report evidence responsibly.
In this guide
- What gaming analytics means
- Game events and analytics workflow
- Ten practical applications
- Essential player metrics
- Fictional tutorial dataset
- Worked calculations and four charts
- Spreadsheet tutorial
- Optional Python tutorial
- Real tools and game AI
- Retention, testing, privacy and well-being
- Six student project ideas
- Four-week study roadmap
- Quiz and answers
- Frequently asked questions
What is data science in gaming?
Game analytics investigates recorded game activity. Game telemetry comprises defined events and measurements from operation. Game design creates rules, progression and challenges; development implements them. Game AI uses different computational decision techniques; machine learning learns patterns from data. These overlap but are not synonymous: a spreadsheet comparison of tutorial completion rates is analytics without AI.
Analysts define questions, validate data, calculate relevant metrics, visualize patterns and present limitations. Developers and designers then investigate potential changes. The Introduction to Data Science explains the broader method.
Common gameplay events and analytical workflow
| Event | Recorded information | Research question or caveat |
|---|---|---|
| Session start/end | Time boundaries | Duration does not prove enjoyment |
| Tutorial start | Eligible entry | Repeat starts complicate totals |
| Checkpoint reached | Progression milestone | Missing events distort funnels |
| Retry / failure | Attempt or restart | A retry can reflect experimentation |
| Hint requested | Help action | Does not prove frustration |
| Tutorial completed | Task finished | Not future retention |
| Crash / latency | Technical signal | Cause requires investigation |
Use a repeatable workflow: research question → event definitions → lawful and safe collection → cleaning → metrics → visualization → feedback → design review → retesting. Audit duplicate identifiers, clock differences, incomplete events and invalid values. GameAnalytics progression documentation explains structured starts, failures and completions.


Udemy · Optional course
An Introduction to Game Analytics
Optional introductory course on game analyst roles, common metrics and professional skills.
Ordinary provider URL; no authorized affiliate tracking. Paid training is optional.
Ten applications of data science in gaming
1. Player behavior analysis
Review aggregate sessions, feature use and attempts to find unexplained patterns. Limitation: Long play does not prove satisfaction.
2. Tutorial progression
Count starts, checkpoints, failures and completions to locate possible barriers. Limitation: Missed events distort funnels.
3. Balancing and difficulty
Compare success, retries, character usage, skill and accessibility feedback. Limitation: Win rate cannot establish fairness alone.
4. Testing and A/B comparisons
Compare interface or tutorial alternatives using predefined outcomes and suitable assignment. Limitation: Small nonrandom groups do not prove causes.
5. Personalization
Recommend modes or preferences using rules or learned models. Limitation: Customization does not require machine learning.
6. Matchmaking
Study skill estimates, match history, latency, team composition and queues. Limitation: Game design and networking also matter.
7. Security investigation
Flag anomalous play or transactions for legitimate review. Limitation: Unusual behavior is not proof of cheating.
8. Performance reliability
Review crashes, frame times, error rates and network delays. Limitation: Measurements do not automatically diagnose faults.
9. Responsible monetization
Examine fair value, complaints, transparent purchases and interruption. Limitation: Never pressure minors to spend more.
10. NPC and procedural systems
Evaluate scripted behavior, pathfinding, AI agents and generated content. Limitation: Procedural generation is not necessarily ML.
| Application | Critical interpretation |
|---|---|
| Player behavior analysis | Long play does not prove satisfaction. |
| Tutorial progression | Missed events distort funnels. |
| Balancing and difficulty | Win rate cannot establish fairness alone. |
| Testing and A/B comparisons | Small nonrandom groups do not prove causes. |
| Personalization | Customization does not require machine learning. |
| Matchmaking | Game design and networking also matter. |
| Security investigation | Unusual behavior is not proof of cheating. |
| Performance reliability | Measurements do not automatically diagnose faults. |
| Responsible monetization | Never pressure minors to spend more. |
| NPC and procedural systems | Procedural generation is not necessarily ML. |
Game analytics metrics: Define denominators
| Metric | Definition |
|---|---|
| Completion rate | Completed eligible sessions ÷ started eligible sessions |
| Checkpoint reach | Checkpoint-reaching sessions ÷ starts |
| Checkpoint conversion | Completions after checkpoint ÷ sessions reaching it |
| Average retries | Total recorded retries ÷ included sessions |
| Average duration | Recorded seconds ÷ included sessions |
| Failure rate | Failures ÷ defined attempts or sessions |
| Retention | Returning unique cohort players ÷ eligible cohort |
Tutorial completion is not Day 1 retention. Retention requires a defined unique-player cohort, date, return window, time zone and follow-up observations. The fictional study below records only one session per imagined tester; it cannot calculate retention.
Signature project: Twelve fictional playtest sessions
Fictional classroom data; no real player information. Tutorial A is standard; Tutorial B uses an alternative arrangement. Six sessions belong to each version, with one session per imaginary tester. This is not a randomized controlled experiment.
Question: How do checkpoint progression, completion, retries, hints and session time differ? Binary flags use 1 for yes and 0 for no. Recorded time includes completed and noncompleting sessions under one assumed measurement window.
| Session | Version | Checkpoint | Completed | Seconds | Retries | Hints |
|---|---|---|---|---|---|---|
| A01 | A | 1 | 1 | 95 | 1 | 0 |
| A02 | A | 1 | 1 | 105 | 0 | 0 |
| A03 | A | 1 | 1 | 120 | 2 | 1 |
| A04 | A | 1 | 1 | 110 | 1 | 0 |
| A05 | A | 1 | 0 | 150 | 3 | 2 |
| A06 | A | 1 | 1 | 100 | 0 | 0 |
| B01 | B | 1 | 1 | 115 | 2 | 1 |
| B02 | B | 1 | 0 | 180 | 4 | 2 |
| B03 | B | 1 | 1 | 125 | 2 | 1 |
| B04 | B | 0 | 0 | 180 | 5 | 2 |
| B05 | B | 1 | 1 | 130 | 3 | 1 |
| B06 | B | 0 | 0 | 170 | 4 | 2 |
Worked game analytics calculations and charts
Checkpoint reach: A = 6 ÷ 6 = 100%; B = 4 ÷ 6 ≈ 66.67%. Completion: A = 5 ÷ 6 ≈ 83.33%; B = 3 ÷ 6 = 50%. Their observed difference is 33.33 percentage points, not a 33.33% relative increase. Combined completion is 8 ÷ 12 ≈ 66.67%.
Progression funnel A: 6 starts → 6 checkpoint visits → 5 completions. Funnel B: 6 → 4 → 3. Checkpoint-to-completion conversion is 5 ÷ 6 ≈ 83.33% for A and 3 ÷ 4 = 75% for B. Compare the same eligible session set.


Calculate retries, hints and session duration
Retries A: 1 + 0 + 2 + 1 + 3 + 0 = 7; average 7 ÷ 6 ≈ 1.17. Retries B: 2 + 4 + 2 + 5 + 3 + 4 = 20; average 20 ÷ 6 ≈ 3.33. Hint totals are 3 for A and 9 for B, giving averages of 0.50 and 1.50.
Time A: 95 + 105 + 120 + 110 + 150 + 100 = 680 seconds, mean 113.33 s. Time B: 115 + 180 + 125 + 180 + 130 + 170 = 900 seconds, mean 150 s. Completed-only means are 106 s (530 ÷ 5) for A and 123.33 s (370 ÷ 3) for B; they exclude unsuccessful sessions.


| Measure | A | B |
|---|---|---|
| Started sessions | 6 | 6 |
| Checkpoint reached | 6 | 4 |
| Completed | 5 | 3 |
| Checkpoint reach | 100% | 66.67% |
| Completion rate | 83.33% | 50% |
| Checkpoint conversion | 83.33% | 75% |
| Mean retries | 1.17 | 3.33 |
| Mean seconds | 113.33 | 150.00 |
| Mean hints | 0.50 | 1.50 |
Interpretation: A recorded more completions, fewer retries and shorter sessions in this invented sample. It does not prove greater fun, accessibility, fairness, player skill or future retention. Real testing should examine sample size, allocation, measurement errors, player experience, learning effects, conditions and statistical uncertainty.
Google Sheets and Excel game analytics tutorial
Enter columns A–G: Session, Version, Checkpoint, Completed, Seconds, Retries and Hints. Copy twelve fictional records into rows 2–13. Validate that completion does not exceed checkpoint status for any row.
| Calculation | Version A formula | Result |
|---|---|---|
| Session count | =COUNTIF(B2:B13,"A") | 6 |
| Reached checkpoint | =COUNTIFS(B2:B13,"A",C2:C13,1) | 6 |
| Completed | =SUMIF(B2:B13,"A",D2:D13) | 5 |
| Completion % | =SUMIF(B2:B13,"A",D2:D13)/COUNTIF(B2:B13,"A") | 83.33% |
| Average retries | =AVERAGEIF(B2:B13,"A",F2:F13) | 1.17 |
| Average seconds | =AVERAGEIF(B2:B13,"A",E2:E13) | 113.33 |
| Average hints | =AVERAGEIF(B2:B13,"A",G2:G13) | 0.50 |
Overall completion: =SUM(D2:D13)/COUNT(D2:D13) gives 66.67%, provided each row represents one eligible started session. Create separate completion, retries, duration and funnel charts with clear units. See data science tools for students.

IBM · Coursera · Optional course
Excel Basics for Data Analysis
Optional spreadsheet practice in formulas, cleaning, grouping and charts for the fictional tutorial analysis.
Ordinary provider URL; no authorized affiliate tracking. Paid training is optional.
Optional Python and Pandas analysis
The code below recreates the twelve-session summary. A calculator or spreadsheet remains enough for the primary exercise.
import pandas as pd
sessions = pd.DataFrame({
"Session": ["A01","A02","A03","A04","A05","A06",
"B01","B02","B03","B04","B05","B06"],
"Version": ["A"]*6 + ["B"]*6,
"Checkpoint": [1,1,1,1,1,1,1,1,1,0,1,0],
"Completed": [1,1,1,1,0,1,1,0,1,0,1,0],
"Seconds": [95,105,120,110,150,100,115,180,125,180,130,170],
"Retries": [1,0,2,1,3,0,2,4,2,5,3,4],
"Hints": [0,0,1,0,2,0,1,2,1,2,1,2]})
assert (sessions["Completed"] <= sessions["Checkpoint"]).all()
summary = sessions.groupby("Version").agg(
Sessions=("Session","count"),
Checkpoints=("Checkpoint","sum"),
Completions=("Completed","sum"),
Mean_Seconds=("Seconds","mean"),
Mean_Retries=("Retries","mean"),
Mean_Hints=("Hints","mean"))
summary["Completion_Rate"] = summary["Completions"]/summary["Sessions"]*100
summary["Checkpoint_Rate"] = summary["Checkpoints"]/summary["Sessions"]*100
summary["Checkpoint_Conversion"] = summary["Completions"]/summary["Checkpoints"]*100
print(summary.round(2))
The DataFrame stores each observation, groupby summarizes versions and percentage calculations use explicit denominators. Real event data need additional checks for duplicate IDs, ordering, missing records, repeated player visits, negative times and privacy. Read Learning Python in High School.
Tools for game analysis and differences from game AI
| Tool | Use and constraints |
|---|---|
| Unity Analytics | Developer-defined events and analysis |
| Roblox Creator Analytics | Authorized game creator dashboards |
| GameAnalytics | Event-based progression and funnels |
| Open Game Data | Research resources for educational games |
| Excel / Google Sheets | Small tables, formulas and graphs |
| Python / Pandas / SQL | Larger game-event data when appropriate |
NPCs may use scripted rules, finite-state machines, behavior trees or pathfinding. Some agents use machine learning, but not all. Procedural level generation may use code and random rules without being trained on data. Game telemetry and machine learning are different concepts. Unverified claims about Fortnite, PUBG, Call of Duty or other proprietary systems have been removed.
Retention, A/B testing, privacy and player well-being
Player retention refers to a specified cohort of unique people returning during a defined later period. Session duration and completion cannot substitute for a return measure. Roblox documents retention dashboards, but conventions may differ across platforms.
A rigorous A/B experiment needs eligibility rules, a predefined outcome, suitable assignment or randomization, appropriate sample sizes, consistent conditions and uncertainty analysis. Our tiny fictional comparison has no p-value, confidence interval or causal evidence. Feedback and accessibility testing may reveal important issues invisible to metrics.
Security analytics can flag unusual activity, but anomalies are not proof of cheating; review and appeals help address false positives. Technical diagnostics measure errors or latency but do not automatically identify their causes. Monetization research should protect fair value, privacy and age-appropriate spending safeguards instead of encouraging compulsive play or pressure to purchase.
Privacy: Use synthetic or appropriately licensed data, consent and lawful processing where relevant, secure storage and minimum necessary collection. Never solicit player passwords, private chats, precise locations, payment histories or children’s identifiable usage profiles. Unity’s privacy documentation does not provide automatic legal compliance; US COPPA applies where relevant and is not a worldwide law.

Six achievable game analytics student projects
Project 1: Tutorial Comparison
Beginner. Analyze this fictional twelve-session study; present rates, retries and uncertainty. Record question, variables, calculations, limitations and safeguards.
Project 2: Game Level Difficulty
Beginner. Make synthetic level starts and completions; compare carefully defined denominators. Record question, variables, calculations, limitations and safeguards.
Project 3: Puzzle Hint Analysis
Beginner. Graph invented hint requests; do not infer a player’s enjoyment from hint counts. Record question, variables, calculations, limitations and safeguards.
Project 4: Error Monitoring
Intermediate. Compare synthetic crash counts by version or device; investigate rather than assume a cause. Record question, variables, calculations, limitations and safeguards.
Project 5: Genre Recommendations
Intermediate. Use invented preferences to demonstrate transparent rule-based suggestions without profiling people. Record question, variables, calculations, limitations and safeguards.
Project 6: Gameplay Funnel
Intermediate. Calculate fictional starts, checkpoints and completions; check event definitions and duplicates. Record question, variables, calculations, limitations and safeguards.
Find related methods in Data Science Projects, Science Fair Research and the Portfolio Guide.
A four-week student learning roadmap
| Week | Main focus | Output |
|---|---|---|
| 1 | Define events and metrics | Research question |
| 2 | Analyze twelve rows | Verified spreadsheet |
| 3 | Visualize and discuss bias | Four-chart report |
| 4 | Present limitations and safeguards | Original portfolio write-up |
A student presentation should contain the title, question, fictional dataset, definitions, calculations, charts, results, limitations, ethical safeguards and credible sources. State what the data do not measure.
Knowledge-check questions and answers
- What is telemetry? Defined gameplay events or technical measurements.
- Completion versus retention? Finishing a task versus returning later.
- Checkpoint count for B? Four of six.
- Overall completion? Eight of twelve, or 66.67%.
- Percentage-point gap? 33.33 points.
- Does longer mean more enjoyable? No.
- Does every NPC use ML? No, rules and behavior trees also work.
- Why minimize data? To protect players and reduce risk.
Frequently asked questions
How is data science used in gaming?
It examines defined gameplay events for progression, difficulty, balancing, reliability, recommendations and accessibility.
What does a game data analyst do?
They define questions, clean records, calculate metrics, visualize results and report limits.
What is game telemetry?
Logged gameplay events such as sessions, retries, hints, checkpoints, completions or technical errors.
How do developers measure difficulty?
They combine completion and retry measures with player skill, accessibility and feedback.
How does retention differ from completion rate?
Completion means finishing a defined task; retention means returning in a defined later window.
How does A/B testing work?
Compare alternative designs with predefined outcomes, suitable allocation and uncertainty analysis.
Do all NPCs use machine learning?
No. Scripted rules, pathfinding and behavior trees do not necessarily learn from data.
Can students learn game analytics without programming?
Yes. A calculator, spreadsheet and fictional twelve-session table are enough.
Conclusion: Better games require more than numbers
Data science can support game design through event analysis, progression measurement, balancing, testing, technical diagnostics and responsible recommendations. It also supports security investigations and accessibility research. But metrics must be interpreted alongside engineering knowledge, ethical safeguards and feedback from players. Screen time, retention and purchases cannot fully describe enjoyment or well-being.
In our invented tutorial comparison, A recorded more completions, fewer retries and shorter sessions than B. This offers a useful classroom example of formulas and funnels, not evidence that A would be better for all real players. A stronger study would address sample size, group assignment, accessibility, uncertainty and satisfaction.
Your challenge: choose a design question, define suitable events, analyze a fictional dataset and explain what further evidence you would need before recommending a real change.
Official references: Unity Analytics, GameAnalytics progression events, Roblox Analytics, Open Game Data and Pandas. Verified November 2026. Disclosure: the optional courses use provider URLs without authorized affiliate tracking.