The basic steps necessary to schedule a project are illustrated using a simple example. Consider a software development project in which an applications developer has the software finished and ready for preliminary testing. In order to complete the project, several activities must take place. Certain activities cannot start until other activities have finished. For instance, the preliminary documentation must be written before it can be revised and edited and before the Quality Assurance department (QA) can test the software. Such constraints among the activities (namely, activity B can start after activity A has finished) are referred to as precedence constraints. Given the precedence constraints and estimated durations of the activities, you can use the critical path method to determine the shortest completion time for the project.
The first step in determining project completion time is to capture the relationships between the activities in a convenient representation. This is done by using a network diagram. Two types of network diagrams are popular for representing a project.
Activity-On-Arc (AOA) or Activity-On-Edge (AOE) diagrams show the activities on the arcs or edges of the network. Figure 4.1 shows the AOA representation for the software project. This method of representing a project is known also as the arrow diagramming method (ADM). For projects represented in the AOA format, PROC CPM requires the use of the following statements:
Activity-On-Node (AON) or Activity-On-Vertex (AOV) diagrams show the activities on nodes or vertices of the network. Figure 4.2 shows the AON representation of the project. This method is known also as the precedence diagramming method (PDM). The AON representation is more flexible because it enables you to specify nonstandard precedence relationships between the activities (for example, you can specify that activity B starts five days after the start of activity A). PROC CPM requires the use of the following statements to schedule projects that are represented using the AON format:
The AON representation of the network is used in the remainder of this section to illustrate some of the features of PROC
CPM.
The project data are input to PROC CPM using a SAS data set. The basic project information is conveyed to PROC CPM through
the ACTIVITY, SUCCESSOR, and DURATION statements. Each observation of the Activity data set
specifies an activity in the project, its duration, and its immediate successors. PROC CPM enables you to specify all of the
immediate successors in the same observation, or you can have multiple observations for each activity, listing each successor
in a separate observation. (Multiple variables in the SUCCESSOR statement are used here.) PROC CPM enables you to use long
activity names. In this example, shorter names are used for the activities to facilitate data entry; a variable, Descrpt
, is used to specify a longer description for each activity.
The procedure determines items such as the following:
No displayed output is produced. However, the results are saved in an output data set (the Schedule data set) that is shown in Figure 4.3.
The code for the entire program is as follows.
data software; format Descrpt $20. Activity $8. Succesr1-Succesr2 $8. ; input Descrpt & Duration Activity $ Succesr1 $ Succesr2 $ ; datalines; Initial Testing 20 TESTING RECODE . Prel. Documentation 15 PRELDOC DOCEDREV QATEST Meet Marketing 1 MEETMKT RECODE . Recoding 5 RECODE DOCEDREV QATEST QA Test Approve 10 QATEST PROD . Doc. Edit and Revise 10 DOCEDREV PROD . Production 1 PROD . . ; proc cpm data=software out=intro1 interval=day date='01mar04'd; id descrpt; activity activity; duration duration; successor succesr1 succesr2; run; title 'Project Schedule'; proc print data=intro1; run;
Figure 4.3: Software Project Plan
Project Schedule |
Obs | Activity | Succesr1 | Succesr2 | Duration | Descrpt | E_START | E_FINISH | L_START | L_FINISH | T_FLOAT | F_FLOAT |
---|---|---|---|---|---|---|---|---|---|---|---|
1 | TESTING | RECODE | 20 | Initial Testing | 01MAR04 | 20MAR04 | 01MAR04 | 20MAR04 | 0 | 0 | |
2 | PRELDOC | DOCEDREV | QATEST | 15 | Prel. Documentation | 01MAR04 | 15MAR04 | 11MAR04 | 25MAR04 | 10 | 10 |
3 | MEETMKT | RECODE | 1 | Meet Marketing | 01MAR04 | 01MAR04 | 20MAR04 | 20MAR04 | 19 | 19 | |
4 | RECODE | DOCEDREV | QATEST | 5 | Recoding | 21MAR04 | 25MAR04 | 21MAR04 | 25MAR04 | 0 | 0 |
5 | QATEST | PROD | 10 | QA Test Approve | 26MAR04 | 04APR04 | 26MAR04 | 04APR04 | 0 | 0 | |
6 | DOCEDREV | PROD | 10 | Doc. Edit and Revise | 26MAR04 | 04APR04 | 26MAR04 | 04APR04 | 0 | 0 | |
7 | PROD | 1 | Production | 05APR04 | 05APR04 | 05APR04 | 05APR04 | 0 | 0 |
In addition to the variables specified in the ACTIVITY, SUCCESSOR, DURATION, and ID statements, the output data set contains the following new variables.
In Figure 4.3 the majority of the tasks have a total float value of 0. These events are critical; that is, any delay in these activities will cause the project to be delayed. Some of the activities have slack present, which means that they can be delayed by that amount without affecting the project completion date. For example, the activity MEETMKT has a slack period of 19 days because there are 19 days between 01MAR04 and 20MAR04.
The INTERVAL= option in the PROC CPM statement enables you to specify the durations of the activities in one of several possible units including days, weeks, months, hours, and minutes. In addition, you can schedule activities around weekends and holidays. (To skip weekends, you specify INTERVAL=WEEKDAY.) You can also select different patterns of work during a day or a week (for example, holidays on Friday and Saturday) and different sets of holidays for the different activities in the project. A calendar consists of a set of work schedules for a typical week and a set of holidays. PROC CPM enables you to define any number of calendars and associate different activities with different calendars.
In the previous example, you saw that you could schedule your project by selecting a project start date. You can also specify a project finish date if you have a deadline to be met and you need to determine the latest start times for the different activities in the project. You can also set constraints on start or finish dates for specific activities within a given project. For example, testing the software may have to be delayed until the testing group finishes another project that has a higher priority. PROC CPM can schedule the project subject to such restrictions through the use of the ALIGNDATE and ALIGNTYPE statements. See Example 4.12 for more information about the use of the ALIGNDATE and ALIGNTYPE statements.
For a project that is already in progress, you can incorporate the actual schedule of the activities (some activities may already be completed while others may still be in progress) to obtain a progress update. You can save the original schedule as a baseline schedule and use it to compare against the current schedule to determine if any of the activities have taken longer than anticipated.
Quite often the resources needed to perform the activities in a project are available only in limited quantities and may cause certain activities to be postponed due to unavailability of the required resources. You can use PROC CPM to schedule the activities in a project subject to resource constraints. A wide range of options enables you to control the scheduling process. For example, you can specify resource or activity priorities, set constraints on the maximum amount of delay that can be tolerated for a given activity, enable activities to be preempted, specify alternate resources that can be used instead of scarce resources, or indicate secondary levels of resources that can be used when the primary levels are insufficient.
When an activity requires multiple resources, it is possible that each resource may follow a different calendar and each may require varying amounts of work. PROC CPM enables you to define resource-driven durations for the activities. You can also specify calendars for the resources. In either of these situations it is possible that each resource used by an activity may have its own individual schedule. PROC CPM enables you to save the resource schedules for the different activities in a Resource Schedule data set, the RESOURCESCHED= data set.
In addition to obtaining a resource-constrained schedule in an output data set, you can save the resource utilization summary in another output data set, the RESOURCEOUT= data set. Several options enable you to control the amount of information saved in this data set.
The CPM procedure enables you to define activities in a multiproject environment with multiple levels of nesting. You can specify a PROJECT variable that identifies the name or number of the project to which each activity belongs.
All the options available with the CPM procedure are discussed in detail in the following sections. Several examples illustrate most of the features.