Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
SlideShare a Scribd company logo
Agile Metrics for
Predicting the Future
@BattistonMattia
Let me tell you a story...
L’aquila
What I’ve learnt
FORECASTS
over
ESTIMATES
Think probabilistically,
not deterministically
FORECASTING
needs
GREAT
COMMUNICATION
Communicate options
& risks, resist bias
against uncertainty
About me
● From Verona, Italy
● Eng. Manager, Agile Coach,
Software Crafter
● Sky, Tesco
● Co-Author of “Team Guide to
Metrics for Business Decisions”
Mattia Battiston
@BattistonMattia
mattia.battiston@gmail.com
Book Discount
http://leanpub.com/
metricsforbusinessdecisions
/c/MATTIA20-BZXib2F
20% Discount:
Business Questions
How long is this going to take?
How much can we get done in XXX time?
Can we finish this by deadline XXX ?
How fast are we going?
...
Story Points?
Low
correlation
https://github.com/Skelton
Thatcher/bizmetrics-book
Why? High WIP
doing donedoing done
Why? Queues
DONENEXT
[3]
DEVELOPMENT
[4]
FUNCTIONAL
TESTING
[3]
WAIT FOR
RELEASE IN
TEST ENV. [3]
RELEASE
TESTING
[5]
WAIT FOR
RELEASE TO
PROD [∞]
QUEUE
(wait time)
VALUE
(touch time)
Why? Unexpected Events
Blockers
Bugs
Emergencies
...
“SMALL
ENOUGH”
The only size that matters
DATA & TOOLS
Data
Enough to start (and goes a long way):
● Story start/end dates
● 5 - 11 samples
Also useful to capture:
● Story metadata (type of work, value/failure
demand, size, etc.)
● Interesting events (helps interpret data)
● Transitions of story between states (to
analyse flow)
Data
Tools?
Spreadsheets (start with this):
● https://github.com/SkeltonThatcher/bizmetrics-book
● http://bit.ly/SimResources (Troy Magennis)
Some Tools:
● https://actionableagile.com/ (Jira, CSV, Trello)
● http://www.senseadapt.com/ (Jira)
● https://marketplace.visualstudio.com/items?itemNam
e=agile-extensions.flowviz (Azure DevOps)
● https://getcorrello.com/ (Trello)
LEAD TIME
Start/End
Start/End
Lead Time Distribution
Q: How long will this story take?
Q: How Long?
Q: How Long?
Q: How long will this story take?
A: We are 80% confident that it won’t
take longer than 9 days
It might take just 4, but there is only a
50% chance so I wouldn’t make any
promises on that
In the worst case scenario we might
need 10 days, but there’s only 10%
chance that this might happen
Q: How Long?
Q: The next scheduled release is in 4
days. Will this story be ready in time?
If it will, I need to train my staff on this
new feature
Q: Will it be ready in time?
Q: Will it be ready in time?
Q: The next scheduled release is in 4
days. Will this story be ready in time?
If it will, I need to train my staff on this
new feature
A: We’re only 50% confident that we can
make it
Q: Will it be ready in time?
Nevermind then, let’s wait for the next
release. Thanks for the honesty
Q: The other team needs us to play this
story to give them a new test
environment. When should we start it?
A: When do they need it by?
Q: When should we start?
3 weeks time
Q: When should we start?
Q: The other team needs us to play this
story to give them a new test
environment. When should we start it?
A: When do they need it by?
Q: When should we start?
3 weeks time
A: We can start it as late as 9 days before
and be 90% confident we can finish it in
time. Let’s not interrupt what we’re doing.
STORY HEALTH
Q: *at standup* What should we give
priority to today?
Q: What shall we work on?
Story Health
Percentile
Days
in progress
Story
Health
0% - 50% < 4
50% - 80% 4 - 9
80% - 90% 9 - 10
90% - 100% > 10
Based on lead time distribution
Story Health
Q: *at standup* What should we give
priority to today?
Q: What shall we work on?
A: The oldest story. Let’s swarm on it and
get it done
THROUGHPUT
Throughput
Throughput
Throughput Stats
Useful spreadsheet at:
https://github.com/SkeltonThatcher/bizmetrics-book
Q: How many stories can we
complete in the next Sprint?
Q: How much can we do?
Q: How much can we do?
Q: How many stories can we
complete in the next Sprint?
Q: How much can we do?
A: We’re 80% confident that we can
complete at least 5 stories. We might get
up to 8, but there’s only 50% chance
Rolling Wave Forecasting
Q: My PO wants us to complete 10
stories in the next sprint, can we do it?
Q: Can we do this much?
Q: Can we do this much?
Q: Can we do this much?
A: We only have 25% confidence. Are we
willing to take such a high risk? What is the
impact of being wrong?
Q: My PO wants us to complete 10
stories in the next sprint, can we do it?
FORECASTING
Q: How long will this project/feature take?
Q: How Long?
Probabilistic Forecasting
● Predict the likelihood of uncertain events
● Monte Carlo simulation: use our historical data to
simulate what might happen in the future
● Result = list of possible outcomes + probability of
that particular outcome to become reality
Useful spreadsheet at:
https://github.com/SkeltonThatcher/bizmetrics-book
Input
Monte Carlo - Mechanics
Randomly extracted from
past throughput
Monte Carlo - Mechanics
After 2 sprints, we simulate
to have completed 8 stories
Monte Carlo - Mechanics
In this simulation, after 5
sprints we have completed
all stories
Monte Carlo - Mechanics
Communicating the Output
Q: How long will this project/feature take?
Q: How Long?
A: We have about 50% chance of
completing the work in 4 sprints, but we
are 85% confident that it won’t take longer
than 5.
In the worst case scenario we might need 6,
but there’s only 15% chance that this might
happen. What would be the impact?
We’ll review our forecast after each sprint
Continuous Forecasting
Continuous Forecasting
Continuous Forecasting
Continuous Forecasting
Continuous Forecasting
Continuous Forecasting
Continuous Forecasting
Q: What can I get in the next 4 sprints?
Q: What can I get?
Q: What can I get?
Q: What can I get in the next 4 sprints?
Q: What can I get?
A: We are 80% confident that we can
complete at least 12 stories in the next 4
sprints.
Q: Will this feature be ready by date X?
Q: Will it be ready in time?
A: This feature was broken down into 10
stories. We’re 60% confident we can
complete all 10 in time.
We are 80% confident we can complete at
least 7 stories. Which ones should we give
priority to?
Less expensive, reviewed often
Reviewed often with new data (e.g. every sprint)
More expensive, no reviews
Need to estimate each story; rarely reviewed
Encourages risk management
Highlights impact of risks
Encourages upfront plans
Often risks are ignored
Flexible scope, allows discovery
Forecast N stories, not important which ones
Fixed-scope, no discovery
Fixates on a particular solution
Reduces personal bias
Based on data instead of personal opinions
Biased towards expectations
We give the result that the client wants to hear
Accounts for queues and problems
Historical data includes queues and past problems
Biased towards active time
We only think about hands-on time, ignoring queues
Inaccurate
Low correlation between estimates and lead time
Accounts for usual utilisation
Historical data reflects usual level of workload
Unreliable when we’re too busy
Even the simplest activities take forever
More accurate
Based on data and measurements
Communicates uncertainty
Expressed as range of outcomes with likelihood
False sense of certainty
Expressed as single number or precise date
ESTIMATE FORECAST
FORECASTING:
TIPS & TRICKS
Tips & Tricks
Use
relevant
data
Account for
“Dark
Matter”
Forecast n.
stories
Ask
Questions
Trust the
people
Debunking Myths - 1
● “I can just use the average”
No, because of “Flaw of averages”. The average can be
very different from what happens in reality, and a
prediction based on averages can therefore be highly
inaccurate.
Moreover, the average being a single number hides
away the range of possible outcomes.
● “This only works if I have a lot of data”
5 to 11 samples is enough to start.
● “This only works if all stories have the same size”
As long as we split stories as small as possible, then it
doesn’t matter if they have different size.
The size of a story has little correlation with its lead
time, which follows a known distribution.
Debunking Myths - 2
● “I can cheat by creating lots of tiny stories”
True, but that’s actually a good side effect. Small
stories have many benefits.
● “I can’t do this, my boss wants a number”
Sometimes people will only want to hear a number. In
this case, you can pick the confidence that you want
to have and communicate that number (but be
aware that you’re missing out on very useful
discussions).
● “If we don’t estimate the team won’t have shared
understanding”
The team still has discussions to break down work
and create shared understanding. We simply don’t
worry about putting a number on stories.
GETTING
STARTED
Getting Started
● Keep doing what you’re doing, but start collecting
data
● Next time you estimate something, also run a
forecast
● Keep updating your forecast with new data
● Review the difference between your estimate and
your forecast
What I’ve learnt
FORECASTS
over
ESTIMATES
Think probabilistically,
not deterministically
FORECASTING
needs
GREAT
COMMUNICATION
Communicate options
& risks, resist bias
against uncertainty
THANK YOU!
really, really appreciated! Help me improve
@BattistonMattia
mattia.battiston@gmail.com
Resources - Books
Resources - Links
Spreadsheets
● https://github.com/SkeltonThatcher/bizmetrics-book - Mattia Battiston & Chris Young
● http://bit.ly/SimResources - Troy Magennis
Metrics
● Kanban Metrics in Practice - Mattia Battiston (video)
● Coaching in a data-driven world - Nick Brown (video)
● Actionable Metrics for Predictability - Dan Vacanti (video)
● How An Expedite Request Sunk the Titanic - Dan Vacanti (video)
● http://bit.ly/SimResources - Troy Magennis (slides)
Forecasting
● Cycle Time Analytics - Troy Magennis (video)
● What’s the story about Agile Data - Troy Magennis (video)
● Forecasting Using Data - Troy Magennis (video)
● Your Project Behaves Like a Hurricane - Dan Vacanti (video)
● #noestimates Project Planning Using Monte Carlo Simulation - Dimitar Bakardzhiev
(video)
● Forecasting Delivery, with Oranges - Dan Brown (video)
● NoEstimates game - Matt Philip (game and resources)
Resources - Links
Story Points
● Story Points and Velocity: The Good Bits - Pawel Brodzinski (article)
● Why you might be wasting your time with Story Point estimation - Ian Carroll (article)
● Story Points Considered Harmful - Vasco Duarte (article)
● Does size matter? - Nader Talai (slides)
● How do you estimate on an Agile project? - Various authors at Thoughtworks (article)
Lead Time
● Inside a Lead Time Distribution - Alexei Zheglov (article)
● Slack Time - Pawel Brodzinski (article)
● Economic Value of Slack Time - Pawel Brodzinski (article)

More Related Content

Agile metrics for predicting the future

  • 1. Agile Metrics for Predicting the Future @BattistonMattia
  • 2. Let me tell you a story... L’aquila
  • 3. What I’ve learnt FORECASTS over ESTIMATES Think probabilistically, not deterministically FORECASTING needs GREAT COMMUNICATION Communicate options & risks, resist bias against uncertainty
  • 4. About me ● From Verona, Italy ● Eng. Manager, Agile Coach, Software Crafter ● Sky, Tesco ● Co-Author of “Team Guide to Metrics for Business Decisions” Mattia Battiston @BattistonMattia mattia.battiston@gmail.com
  • 6. Business Questions How long is this going to take? How much can we get done in XXX time? Can we finish this by deadline XXX ? How fast are we going? ...
  • 10. doing donedoing done Why? Queues DONENEXT [3] DEVELOPMENT [4] FUNCTIONAL TESTING [3] WAIT FOR RELEASE IN TEST ENV. [3] RELEASE TESTING [5] WAIT FOR RELEASE TO PROD [∞] QUEUE (wait time) VALUE (touch time)
  • 14. Data Enough to start (and goes a long way): ● Story start/end dates ● 5 - 11 samples Also useful to capture: ● Story metadata (type of work, value/failure demand, size, etc.) ● Interesting events (helps interpret data) ● Transitions of story between states (to analyse flow)
  • 15. Data
  • 16. Tools? Spreadsheets (start with this): ● https://github.com/SkeltonThatcher/bizmetrics-book ● http://bit.ly/SimResources (Troy Magennis) Some Tools: ● https://actionableagile.com/ (Jira, CSV, Trello) ● http://www.senseadapt.com/ (Jira) ● https://marketplace.visualstudio.com/items?itemNam e=agile-extensions.flowviz (Azure DevOps) ● https://getcorrello.com/ (Trello)
  • 21. Q: How long will this story take? Q: How Long?
  • 23. Q: How long will this story take? A: We are 80% confident that it won’t take longer than 9 days It might take just 4, but there is only a 50% chance so I wouldn’t make any promises on that In the worst case scenario we might need 10 days, but there’s only 10% chance that this might happen Q: How Long?
  • 24. Q: The next scheduled release is in 4 days. Will this story be ready in time? If it will, I need to train my staff on this new feature Q: Will it be ready in time?
  • 25. Q: Will it be ready in time?
  • 26. Q: The next scheduled release is in 4 days. Will this story be ready in time? If it will, I need to train my staff on this new feature A: We’re only 50% confident that we can make it Q: Will it be ready in time? Nevermind then, let’s wait for the next release. Thanks for the honesty
  • 27. Q: The other team needs us to play this story to give them a new test environment. When should we start it? A: When do they need it by? Q: When should we start? 3 weeks time
  • 28. Q: When should we start?
  • 29. Q: The other team needs us to play this story to give them a new test environment. When should we start it? A: When do they need it by? Q: When should we start? 3 weeks time A: We can start it as late as 9 days before and be 90% confident we can finish it in time. Let’s not interrupt what we’re doing.
  • 31. Q: *at standup* What should we give priority to today? Q: What shall we work on?
  • 32. Story Health Percentile Days in progress Story Health 0% - 50% < 4 50% - 80% 4 - 9 80% - 90% 9 - 10 90% - 100% > 10 Based on lead time distribution
  • 34. Q: *at standup* What should we give priority to today? Q: What shall we work on? A: The oldest story. Let’s swarm on it and get it done
  • 40. Q: How many stories can we complete in the next Sprint? Q: How much can we do?
  • 41. Q: How much can we do?
  • 42. Q: How many stories can we complete in the next Sprint? Q: How much can we do? A: We’re 80% confident that we can complete at least 5 stories. We might get up to 8, but there’s only 50% chance
  • 44. Q: My PO wants us to complete 10 stories in the next sprint, can we do it? Q: Can we do this much?
  • 45. Q: Can we do this much?
  • 46. Q: Can we do this much? A: We only have 25% confidence. Are we willing to take such a high risk? What is the impact of being wrong? Q: My PO wants us to complete 10 stories in the next sprint, can we do it?
  • 48. Q: How long will this project/feature take? Q: How Long?
  • 49. Probabilistic Forecasting ● Predict the likelihood of uncertain events ● Monte Carlo simulation: use our historical data to simulate what might happen in the future ● Result = list of possible outcomes + probability of that particular outcome to become reality
  • 51. Input
  • 52. Monte Carlo - Mechanics Randomly extracted from past throughput
  • 53. Monte Carlo - Mechanics After 2 sprints, we simulate to have completed 8 stories
  • 54. Monte Carlo - Mechanics In this simulation, after 5 sprints we have completed all stories
  • 55. Monte Carlo - Mechanics
  • 57. Q: How long will this project/feature take? Q: How Long? A: We have about 50% chance of completing the work in 4 sprints, but we are 85% confident that it won’t take longer than 5. In the worst case scenario we might need 6, but there’s only 15% chance that this might happen. What would be the impact? We’ll review our forecast after each sprint
  • 65. Q: What can I get in the next 4 sprints? Q: What can I get?
  • 66. Q: What can I get?
  • 67. Q: What can I get in the next 4 sprints? Q: What can I get? A: We are 80% confident that we can complete at least 12 stories in the next 4 sprints.
  • 68. Q: Will this feature be ready by date X? Q: Will it be ready in time? A: This feature was broken down into 10 stories. We’re 60% confident we can complete all 10 in time. We are 80% confident we can complete at least 7 stories. Which ones should we give priority to?
  • 69. Less expensive, reviewed often Reviewed often with new data (e.g. every sprint) More expensive, no reviews Need to estimate each story; rarely reviewed Encourages risk management Highlights impact of risks Encourages upfront plans Often risks are ignored Flexible scope, allows discovery Forecast N stories, not important which ones Fixed-scope, no discovery Fixates on a particular solution Reduces personal bias Based on data instead of personal opinions Biased towards expectations We give the result that the client wants to hear Accounts for queues and problems Historical data includes queues and past problems Biased towards active time We only think about hands-on time, ignoring queues Inaccurate Low correlation between estimates and lead time Accounts for usual utilisation Historical data reflects usual level of workload Unreliable when we’re too busy Even the simplest activities take forever More accurate Based on data and measurements Communicates uncertainty Expressed as range of outcomes with likelihood False sense of certainty Expressed as single number or precise date ESTIMATE FORECAST
  • 71. Tips & Tricks Use relevant data Account for “Dark Matter” Forecast n. stories Ask Questions Trust the people
  • 72. Debunking Myths - 1 ● “I can just use the average” No, because of “Flaw of averages”. The average can be very different from what happens in reality, and a prediction based on averages can therefore be highly inaccurate. Moreover, the average being a single number hides away the range of possible outcomes. ● “This only works if I have a lot of data” 5 to 11 samples is enough to start. ● “This only works if all stories have the same size” As long as we split stories as small as possible, then it doesn’t matter if they have different size. The size of a story has little correlation with its lead time, which follows a known distribution.
  • 73. Debunking Myths - 2 ● “I can cheat by creating lots of tiny stories” True, but that’s actually a good side effect. Small stories have many benefits. ● “I can’t do this, my boss wants a number” Sometimes people will only want to hear a number. In this case, you can pick the confidence that you want to have and communicate that number (but be aware that you’re missing out on very useful discussions). ● “If we don’t estimate the team won’t have shared understanding” The team still has discussions to break down work and create shared understanding. We simply don’t worry about putting a number on stories.
  • 75. Getting Started ● Keep doing what you’re doing, but start collecting data ● Next time you estimate something, also run a forecast ● Keep updating your forecast with new data ● Review the difference between your estimate and your forecast
  • 76. What I’ve learnt FORECASTS over ESTIMATES Think probabilistically, not deterministically FORECASTING needs GREAT COMMUNICATION Communicate options & risks, resist bias against uncertainty
  • 77. THANK YOU! really, really appreciated! Help me improve @BattistonMattia mattia.battiston@gmail.com
  • 79. Resources - Links Spreadsheets ● https://github.com/SkeltonThatcher/bizmetrics-book - Mattia Battiston & Chris Young ● http://bit.ly/SimResources - Troy Magennis Metrics ● Kanban Metrics in Practice - Mattia Battiston (video) ● Coaching in a data-driven world - Nick Brown (video) ● Actionable Metrics for Predictability - Dan Vacanti (video) ● How An Expedite Request Sunk the Titanic - Dan Vacanti (video) ● http://bit.ly/SimResources - Troy Magennis (slides) Forecasting ● Cycle Time Analytics - Troy Magennis (video) ● What’s the story about Agile Data - Troy Magennis (video) ● Forecasting Using Data - Troy Magennis (video) ● Your Project Behaves Like a Hurricane - Dan Vacanti (video) ● #noestimates Project Planning Using Monte Carlo Simulation - Dimitar Bakardzhiev (video) ● Forecasting Delivery, with Oranges - Dan Brown (video) ● NoEstimates game - Matt Philip (game and resources)
  • 80. Resources - Links Story Points ● Story Points and Velocity: The Good Bits - Pawel Brodzinski (article) ● Why you might be wasting your time with Story Point estimation - Ian Carroll (article) ● Story Points Considered Harmful - Vasco Duarte (article) ● Does size matter? - Nader Talai (slides) ● How do you estimate on an Agile project? - Various authors at Thoughtworks (article) Lead Time ● Inside a Lead Time Distribution - Alexei Zheglov (article) ● Slack Time - Pawel Brodzinski (article) ● Economic Value of Slack Time - Pawel Brodzinski (article)