The Proper Way to Estimate Time
A proven technique to never miss your deadlines again
I work as a programmer, I create a game, and I write blogs. If there one thing all of these things need then it is time estimation.
Probably one of the hardest questions to answer as a programmer is:
How long does it take to implement this?
Because: Well, good question. I don’t know!
Does not count as an answer, programmers tend to pause a while and then give out a rough time estimate — which most of the time is wrong.
And you can’t blame them. They are just humans too, and they don’t own a glass ball which allows them to see the future.
Often we can’t make precise time estimations because projects are to complex. A small bugfix can result in a large problem faster than you might think.
Good time estimation is important.
Not only projects suffer from bad estimated time, but it is also a bad feeling for the person working on a task which should be finished a while ago.
But we are lucky! Some techniques allow us to estimate time much more precisely.
One of them is called PERT. I learned this method at my previous workplace and it has proven itself to me, so I want to show you what it is and how to use it.
PERT (Program Evaluation and Review Technique) was created by the US navy back in 1958 where it was used to estimate the time to develop ballistic missiles launched from submarines.
Most of us probably don’t work on such massive projects, but don’t worry, PERT works fine for smaller tasks too.
How to use
PERT uses three estimated times to estimate the expected time (E):
- Optimistic time (O)
- Pessimistic time (P)
- Most likely time (M)
O is the time you estimated the task would take if everything goes like expected e.g. the fastest time you think you can finish the task.
P is the opposite of O. Estimate the time you think you would need if everything doesn’t work as you expect.
M is the time you would think is the most realistic one to finish the task.
Depending on your task, the estimated times can be in any size you want(minutes, hours, days…).
After you estimated all three times, you can get the expected time with this equation:
Expected time (E) = (O + 4M + P)/6
Because E is only a time estimate from estimated values. It is safer to calculate a variance (V) = ((P-O)/6)².
E +/- V is your timeframe where your task has the highest probability to be finished.
I will not explain the math behind PERT, which would break the scope of this blog and is not needed if you just want to use it.
If you are interested you can read more here:
To make things more clear, let’s practice a bit!
Let’s say you estimated:
- O = 2 hours
- P = 8 hours
- M = 5 hours
Your expected time E would be calculated like this:
E =(2 + 5*4 + 8)/6 = 5
The variance V would be calculated like this:
V = ((8–2)/6)² =1
So your estimated time for this task would be 4–6 hours.
You see, PERT is an effective method to estimate times. When estimating, it is important to take some time and think about the task you are about to do. The more you know the task the easier it gets to estimate the time for it.
If you have any questions, feel free to ask me!