As some of you may already know the PERT Addin that was in Project for several versions was NOT included in Project 2010. The good news is that below we have the first version of some sample code you can use to add the feature back into the product! This first version does not use a form like the old one. It uses custom fields at the task level to store the Pessimistic, Optimistic and Most Likely estimates and the weights for each estimate. This is just a preliminary version. We hope to gather feedback and then release a future version of the code as a Visual Studio project that can be customized and used to create a Project 2010 Addin.
This code depends on using 7 task level custom fields:
The image below shows a Gantt Chart view with these fields inserted. In this example we see weights only on the first task. This is an option you can set in the code. If the option is set to ‘False’ then each task can have its own set of weights. Duration estimates are inserted for each task. The code at this point will estimate every task. (We could add the option to allow a project manager to specify which tasks should be estimated.)
To use this sample code in your own projects:
Now the code is ready to be used. All that is left is to insert the fields in the table above into a Gantt Chart view, enter your estimates and your weights (Remember that the weights must add up to 6!!) and then run the macro using the Quick Launch button you just added.
This is just a first pass at a sample for replacing the PERT functionality. Please email me (firstname.lastname@example.org) with your feedback.
Some things to think about:
One last thing: This is just sample code and should be thoroughly tested before you use it on a ‘production’ project.
Sub PERT()Dim tskT As TaskDim tskFirst As TaskDim FoundBadWeights As BooleanDim UseOneSetofWeights As Boolean
UseOneSetofWeights = TrueFoundBadWeights = False
CustomFieldRename FieldID:=pjCustomTaskDuration1, NewName:="Optimistic Duration"CustomFieldRename FieldID:=pjCustomTaskDuration2, NewName:="Most Likely Duration"CustomFieldRename FieldID:=pjCustomTaskDuration3, NewName:="Pessimistic Duration"CustomFieldRename FieldID:=pjCustomTaskNumber1, NewName:="Optimistic Weight"CustomFieldRename FieldID:=pjCustomTaskNumber2, NewName:="Most Likely Weight"CustomFieldRename FieldID:=pjCustomTaskNumber3, NewName:="Pessimistic Weight"CustomFieldRename FieldID:=pjCustomTaskText30, NewName:="PERT State"
If UseOneSetofWeights = True Then Set tskFirst = ActiveProject.Tasks(1) For Each tskT In ActiveProject.Tasks If Not (tskT Is Nothing) Then If tskT.PercentComplete = 0 And tskT.PercentWorkComplete = 0 Then If (tskFirst.Number1 + tskFirst.Number2 + tskFirst.Number3) = 6 Then tskT.Duration = ((((tskT.Duration1) * tskFirst.Number1) _ + ((tskT.Duration2) * tskFirst.Number2) _ + ((tskT.Duration3) * tskFirst.Number3)) / 6) tskT.Text30 = "Duration Calc'd: " & Now() Else tskT.Text30 = "Not Calc'd: Weights <> 6" FoundBadWeights = True End If Else tskT.Text30 = "Not Calc'd: Task In Progress or Complete" End If End If Next tskTElse For Each tskT In ActiveProject.Tasks If Not (tskT Is Nothing) Then If tskT.PercentComplete = 0 And tskT.PercentWorkComplete = 0 Then If (tskT.Number1 + tskT.Number2 + tskT.Number3) = 6 Then tskT.Duration = ((((tskT.Duration1) * tskT.Number1) _ + ((tskT.Duration2) * tskT.Number2) _ + ((tskT.Duration3) * tskT.Number3)) / 6) tskT.Text30 = "Duration Calc'd: " & Now() Else tskT.Text30 = "Not Calc'd: Weights <> 6" FoundBadWeights = True End If Else tskT.Text30 = "Not Calc'd: Task In Progress or Complete" End If End If Next tskTEnd IfIf FoundBadWeights = True Then MsgBox Prompt:="Some Tasks Weight Values were found to be incorrect." & _ Chr(13) & "Check the Text30 fields for details.", Buttons:=vbCritical, _ Title:="WorkPERT Weights Error"End IfEnd Sub
Since the original A+4B+C formula was reverse engieered from a Beta distribution with symetric standard deviations. The Beta was "converted" to a static form through the A+4B+C construct
What is the impact on the confidence intervales for the resulting PERT estimate when changes are made to the weighting factors and at the same time the A,B,C estimate are not drawn from the underlying symmetric Beta distribution?
Analysis of PERT also shows up to a 27% unfavorable bias in the projected completion date if the Beta symmetry is not maintained in the actual project sample data. Along with ignoring (which PERT does) the correlations between tasks and the none symmetric behaviors of the actual data distributions. The tools you have "may" have unexpected outcomes that are far removed from actual project behaviors.
Happy Thanksgiving. But think about the nonlinear cooking times of turkeys. The cooking time of turkeys is related to the surface area - a Rayleigh distribution - a cousin of the Beta.
for sure if you are looking for full stregnth multi-estimate modeling for your scheduling then there are certainly add in tools that go the fully distance.
What Im doing here is just a step toward getting the old PERT functionality back into the product in a very lightweight way.
Luckily, my thanksgiving schedule did not include a formulaic estimation of cooking time. I took mine out of the recipe, which did NOT factor in cooking in a convection oven by the way. It said 2 hours 10 mins and it cooked to 10 degrees higher than spec in 1 hour 50 mins! :-)
I think the idea for triple point estimates was under utilized in earlier versions of Project which may be why it has been eliminated. I have been beta testing P2010 since March and it never dawned on me to even look for this feature...
I like your ideas and will try the code. To answer your questions, I usually enter PERT time estimates directly in the columns so a form would not be a big benefit to me. Form for setting weights is good, go for it, along with the ability to estimate certain tasks and not others.
Next, consider makeing the fields flexible ... many of us already have some of the field spoken for because we integrate with other programs like COBRA, etc. So I would like the ability to determine which field becomes "Pessimistic Duration" etc
In closing, I wonder how much use this will receive. I would rather purchase something like Risk+ or RiskyProject add-ins for MS Project and use the full robust features of the add-ins to take advantage of the PERT times and Monte Carlo runs.
One of the issues I had with the Project PERT times was they were all static and I could show an optimistic, pessimistic, expected Gantt. In reality, none of these is ever going to happen. My main issue with Project PERT was knowing what to do with the data, as opposed to a Monte Carlo based program that can tie real statistics to the triple point estimates.
Charge on! I look forward to your next incantation.
Hello. Just curious what the rationale was for omitting the PERT features in P2010
Really helpful, worked perfect.