Nonstandard Relationships (cpme11)
/****************************************************************/
/* S A S S A M P L E L I B R A R Y */
/* */
/* NAME: CPME11 */
/* TITLE: Nonstandard Relationships (cpme11) */
/* PRODUCT: OR */
/* SYSTEM: ALL */
/* KEYS: CPM */
/* PROCS: CPM */
/* DATA: */
/* */
/* SUPPORT: UPDATE: */
/* REF: Example 11 from the CPM Chapter (PM User's Guide) */
/* MISC: */
/* */
/****************************************************************/
/* Activity-on-Node representation of the project with lags */
data widglag;
input task $ 1-12 days succ $ 19-30 lagdur $ 33-37 lagdurc $ 40-52;
datalines;
Approve Plan 5 Drawings
Approve Plan 5 Study Market
Approve Plan 5 Write Specs
Drawings 10 Prototype
Study Market 5 Mkt. Strat.
Write Specs 5 Prototype
Prototype 15 Materials ss_9 ss_9
Prototype 15 Facility ss_9 ss_9
Mkt. Strat. 10 Test Market
Mkt. Strat. 10 Marketing
Materials 10 Init. Prod.
Facility 10 Init. Prod. fs_2 fs_2_SEVENDAY
Init. Prod. 10 Test Market
Init. Prod. 10 Marketing
Init. Prod. 10 Evaluate
Evaluate 10 Changes
Test Market 15 Changes
Changes 5 Production
Production 0
Marketing 0
;
title 'Non-Standard Relationships';
title2 'Activity Data Set WIDGLAG';
proc print;
run;
proc cpm data=widglag date='1dec03'd
interval=weekday collapse out=lagsched;
activity task;
succ succ / lag = (lagdur);
duration days;
run;
title 'Non-Standard Relationships';
title2 'Lag Type and Duration: Default LAG Calendar';
proc print;
id task;
var e_: l_: t_float f_float;
run;
data calendar;
input _cal_ $ _sun_ $ _mon_$ _tue_$ _wed_$ _thu_$ _fri_$ _sat_ $;
datalines;
SEVENDAY workday workday workday workday workday workday workday
;
title 'Non-Standard Relationships';
title2 'Calendar Data Set';
proc print;
run;
proc cpm data=widglag date='1dec03'd calendar=calendar
interval=weekday collapse out=lagsched;
activity task;
succ succ / lag = (lagdurc);
duration days;
run;
title 'Non-Standard Relationships';
title2 'Lag Type, Duration, and Calendar';
proc print;
id task;
var e_: l_: t_float f_float;
run;
proc cpm data=widglag date='1dec03'd calendar=calendar
interval=weekday collapse out=lagsched;
activity task;
succ succ / lag = (lagdur) alagcal=sevenday;
duration days;
run;
title 'Non-Standard Relationships';
title2 'Lag Type and Duration: LAG Calendar = SEVENDAY';
proc print;
id task;
var e_: l_: t_float f_float;
run;
pattern1 c=green v=s; /* duration of a non-critical activity */
pattern2 c=green v=e; /* slack time for a noncrit. activity */
pattern3 c=red v=s; /* duration of a critical activity */
title h=1.5 'Non-Standard Relationships';
title2 h=1 'Precedence Gantt Chart';
proc gantt graphics data=lagsched logic=widglag;
chart / compress act=task succ=(succ) dur=days
cprec=black cmile=blue
caxis=black
height=1.5 nojobnum
dur=days increment=7 lag=(lagdur);
id task;
run;