Chapter Contents
Chapter Contents
Introduction to the FACTEX Procedure

Example of a Two-Level Full Factorial Design

This example FACTEXG1 introduces the basic syntax used with the FACTEX procedure.

An experimenter is interested in studying the effects of three factors - cutting speed (SPEED), feed rate (FEED), and tool angle (ANGLE) - on the surface finish of a metallic part. Two levels of each factor are chosen (shown below), and the experimenter decides to run a complete factorial experiment.

Factor Low Level High Level
Cutting Speed300500
Feed Rate2030
Tool Angle68

This is a 23 factorial design - in other words, a complete factorial experiment with three factors, each at two levels. Hence there are eight runs in the experiment. Since complete factorial designs have full resolution, all of the main effects and interaction terms can be estimated. For a definition of the design resolution, see "Resolution" .

You can use the following statements to create the required design:

   proc factex;                    /* Invoke the FACTEX procedure */
      factors speed feed angle;    /* List factor names           */
      examine design;              /* Display coded design points */

By default, the FACTEX procedure assumes that the size of the design is a full factorial and that each factor has only two levels.

After you submit the preceding statements, you will see the following messages in the SAS log:

NOTE: No design size specified.
Default is a full replicate in 8 runs.
NOTE: Design has 8 runs, full resolution.

The output is shown in Figure 14.1. The two factor levels are represented by the coded values 1 and -1.

The FACTEX Procedure

Design Points
speed feed angle
1 -1 -1 -1
2 -1 -1 1
3 -1 1 -1
4 -1 1 1
5 1 -1 -1
6 1 -1 1
7 1 1 -1
8 1 1 1
Figure 14.1: 23 Factorial Design

If you prefer to work with the actual (decoded) values of the factors, you can specify these values in an OUTPUT OUT= statement, as follows:

   proc factex;
      factors speed feed angle;
      output out=savdesgn             /* Recode factor levels and  */
             speed nvals=(300 500)    /*   save design in SAVDESGN */
             feed  nvals=(20  30 )
             angle nvals=(6   8  );
   proc print;

Since the levels in this example are of numeric type, you use the NVALS= option to list the factor levels. Optionally, you can use the CVALS= option for levels of character type (see "Example of a Full Factorial Design in Two Blocks" ). The design is saved in a user-specified output data set (SAVDESGN). This is verified by the following message in the SAS log:

NOTE: The data set WORK.SAVDESGN has 8 observations
and 3 variables.

Figure 14.2 shows a listing of the data set SAVDESGN.

Obs speed feed angle
1 300 20 6
2 300 20 8
3 300 30 6
4 300 30 8
5 500 20 6
6 500 20 8
7 500 30 6
8 500 30 8
Figure 14.2: 23 Factorial Design after Decoding

Although small complete factorial designs are not difficult to create manually, you can easily extend this example to construct a design with many factors.

Chapter Contents
Chapter Contents

Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.