Resources

Schematic Diagrams (netdr12)

/****************************************************************/
/*          S A S   S A M P L E   L I B R A R Y                 */
/*                                                              */
/*    NAME: NETDR12                                             */
/*   TITLE: Schematic Diagrams (netdr12)                        */
/* PRODUCT: OR                                                  */
/*  SYSTEM: ALL                                                 */
/*    KEYS: NETDRAW                                             */
/*   PROCS: CPM, NETDRAW                                        */
/*    DATA:                                                     */
/*                                                              */
/* SUPPORT:                             UPDATE:                 */
/*     REF: Example 12 from the NETDRAW Chapter(PM User's Guide)*/
/*    MISC:                                                     */
/*                                                              */
/****************************************************************/


data dataflow;
   format id1 $18. id2 $14. id3 $19. ;
   input a $ b $ id1 & id2 & id3 & style;
   datalines;
A B Data Definition:    PROC FSEDIT,    SAS/AF, etc.         2
B C Data Manipulation:  Sort, Merge,    Concatenate, etc.    2
B D Data Manipulation:  Sort, Merge,    Concatenate, etc.    2
D C .                   PROC NETDRAW    .                    1
C E PROC CPM            .               PROC PM              1
C F PROC CPM            .               PROC PM              1
E H Resource Usage      .               Data                 3
F G .                   Schedule Data   .                    3
G I Data Manipulation:  Sort, Merge,    Subset, etc.         2
G J Data Manipulation:  Sort, Merge,    Subset, etc.         2
H K Data Manipulation:  Sort, Merge,    Subset, etc.         2
I . Other Reporting     PROC's: PRINT,  CALENDAR, etc.       2
J . PROC GANTT          .               PROC NETDRAW         1
K . Reporting PROC's:   PLOT, CHART,    GPLOT, GCHART, etc.  2
;


pattern1 v=s c=red;
pattern2 v=s c=blue;
pattern3 v=s c=green;

goptions hpos=110 vpos=70;
title h=3 'A Typical Project Management System';
title2 h=2.5  'Schematic Representation of Data Flow';
proc netdraw data=dataflow graphics;
   actnet / act=a succ=b id = (id1-id3)
            nodefaultid
            nolabel
            pattern=style
            carcs=black coutline=black ctext=white
            hmargin = 2
            ybetween = 15
            rectilinear
            noarrowfill
            pcompress htext=2;
   run;


data outage;
   input a $ b $ id1 $20.  id2 $20. style;
   datalines;
A   B   Project            Definition             1
B   C   CPM                Schedule               2
C   D   Gantt Chart        Network                3
D   E   Start Power        Outage                 4
E   F   Project            Update                 1
F   G   Schedule           Update                 2
G   E   Gantt Chart        Network                3
;


goptions hpos=110 vpos=70;
title h=3 'Scheduling an Outage';
title2 h=2.5  'Project Cycle';

pattern1 v=s c=green;
pattern2 v=s c=blue;
pattern3 v=s c=blue;
pattern4 v=s c=red;

proc netdraw data=outage graphics;
   actnet / act=a succ=b id = (id1 id2)
            breakcycle
            nodefaultid centerid
            vmargin = 5 hmargin = 0
            nolabel novcenter
            pattern=style
            carcs=black coutline=black ctext=white
            ybetween = 15 xbetween=3
            noarrowfill
            pcompress htext=2;
   run;