Chapter Contents |
Previous |
Next |
Macros for the Design and Analysis of Experiments |
%adxcode(dsin, dsout, vlst, bvar)
dsin | names the SAS data set that contains the design to be coded. |
dsout | names the output SAS data set that contains the coded design. The value of dsout can be the same as dsin; this simply replaces the uncoded design with the coded design. |
vlst | lists the design factors. |
bvar | names the block factor. If the design does not contain a block factor, omit bvar. |
The ADXCODE macro translates uncoded values of design and block factors into coded values. Once an experiment has been run and you are ready to analyze the resulting data, values for the design factors must be coded into the standard values of -1, 0, +1, and so on. This makes the estimated effects of different factors directly comparable. Note that the ADXFFA macro, which performs analysis of fractional factorial designs, assumes that the data are coded.
For example, suppose you have an uncoded design stored in the data set REACTOR. The design factors are TIME, ROTOR, OVEN, GLUE, and TEMP. The block factor is DAY. You can code the factor values with the following macro call:
%adxgen %adxcode(reactor,reactor,time rotor oven glue temp,day)
In the call above, the new, coded data set is named REACTOR. The uncoded data is no longer available.
The example above uses factor names other than the default names (T1, T2, and so on). To rename factors from the defaults, use the ADXDCODE macro, which is discussed below. The ADXCODE macro performs the opposite function of the ADXDCODE macro, except that the ADXCODE macro does not reset factor names to the defaults.
Chapter Contents |
Previous |
Next |
Top |
Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.