The %MktOrth autocall macro lists some of the 100% orthogonal main-effects plans that the %MktEx macro can generate.
%MktOrth( <optional arguments>)
You can specify either of the following to display the argument names and simple examples of the macro syntax:
%mktorth(help) %mktorth(?)
This macro specifies options nonotes
throughout most of its execution. If you want to see all the notes, submit the following statement before running the macro:
%let mktopts = notes;
To see the macro version, submit the following statement before running the macro:
%let mktopts = version;
The %MktOrth macro is usually used indirectly; it is called by the %MktEx macro. However, you can directly call the %MktOrth macro to see what orthogonal designs are available and decide which ones to use. The following statement requests all the designs in the catalog that have 100 or fewer runs and 2-level through 6-level factors (with no higher-level factors):
%mktorth(maxn=100, maxlev=6)
The macro creates data sets and displays no output except the following notes:
NOTE: The data set WORK.MKTDESLEV has 357 observations and 9 variables. NOTE: The data set WORK.MKTDESCAT has 357 observations and 3 variables.
The next statement generates the entire catalog of 121,270 designs, including more than 62,000 designs in 512 runs that are not generated by default:
%mktorth(maxlev=144, options=512)
The next statement generates the catalog of 58,690 designs, including designs that have up to 144-level factors:
%mktorth(maxlev=144)
Unless you really want to see all the designs, you can make the %MktOrth macro run much faster by specifying smaller values for the RANGE= or MAXN= argument (to control the number of runs) and the MAXLEV= argument (to control the maximum number of factor levels and the number of variables in the MKTDESLEV data set) than the defaults (RANGE= N LE 1000, MAXN=1000, MAXLEV=50). The maximum number of levels that you can specify is 144.
The following statement lists the first few and last few designs in the catalog:
proc print data=mktdeslev(where=(n le 12 or n ge 972)); var design reference; id n; by n; run;
Some of the results are as follows:
n Design Reference 4 2 ** 3 Hadamard 6 2 ** 1 3 ** 1 Full-Factorial 8 2 ** 7 Hadamard 2 ** 4 4 ** 1 Fractional-Factorial 9 3 ** 4 Fractional-Factorial 10 2 ** 1 5 ** 1 Full-Factorial 12 2 ** 11 Hadamard 2 ** 4 3 ** 1 Orthogonal Array 2 ** 2 6 ** 1 Orthogonal Array 3 ** 1 4 ** 1 Full-Factorial 972 2 **971 Hadamard 976 2 **975 Hadamard 2 **972 4 ** 1 Orthogonal Array 2 **969 4 ** 2 Orthogonal Array 2 **968 8 ** 1 Orthogonal Array 2 **966 4 ** 3 Orthogonal Array 984 2 **983 Hadamard 2 **980 4 ** 1 Orthogonal Array 992 2 **991 Hadamard 2 **988 4 ** 1 Orthogonal Array 2 **985 4 ** 2 Orthogonal Array 2 **984 8 ** 1 Orthogonal Array 2 **982 4 ** 3 Orthogonal Array 2 **979 4 ** 4 Orthogonal Array 2 **976 4 ** 5 Orthogonal Array 2 **976 16 ** 1 Orthogonal Array 2 **973 4 ** 6 Orthogonal Array 2 **970 4 ** 7 Orthogonal Array 1000 2 **999 Hadamard 2 **996 4 ** 1 Orthogonal Array
In most ways, the catalog stops at 513 runs. The exceptions include in 576 runs, in 676 runs, Hadamard designs up to = 1,000, and designs easily constructed from those Hadamard designs (by creating 4-level factors, 8-level factors, 16-level factors, and so on).
The following statement displays the first few designs and variables in the MktDesLev
data set:
proc print data=mktdeslev(where=(n le 12)); var design reference x1-x6; id n; by n; run;
Some of the results are as follows:
n Design Reference x1 x2 x3 x4 x5 x6 4 2 ** 3 Hadamard 0 3 0 0 0 0 6 2 ** 1 3 ** 1 Full-Factorial 0 1 1 0 0 0 8 2 ** 7 Hadamard 0 7 0 0 0 0 2 ** 4 4 ** 1 Fractional-Factorial 0 4 0 1 0 0 9 3 ** 4 Fractional-Factorial 0 0 4 0 0 0 10 2 ** 1 5 ** 1 Full-Factorial 0 1 0 0 1 0 12 2 ** 11 Hadamard 0 11 0 0 0 0 2 ** 4 3 ** 1 Orthogonal Array 0 4 1 0 0 0 2 ** 2 6 ** 1 Orthogonal Array 0 2 0 0 0 1 3 ** 1 4 ** 1 Full-Factorial 0 0 1 1 0 0
If you want to display only a list of designs, possibly selecting on the number of runs , you can use the MktDesCat
data set. However, if you want to do more advanced processing, based on the numbers of levels of some of the factors, you can use the OUTLEV=MktDesLev
data set to select potential designs. You can look at the level information in MktDesLev
and see the number of 2-level factors in X2
, the number of 3-level factors in X3
, and so on, up to the number of 144-level factors in X144
. The number of 1-level factors, X1
, is always zero, but X1
is available so you can make arrays (for example, array x[50]
) and have x[2]
refer to X2
, the number of 2-level factors, and so on.
Suppose you are interested in the design . The following statements display some of the ways in which it is available:
%mktorth(maxn=100) proc print data=mktdeslev noobs; where x2 ge 5 and x3 ge 5 and x4 ge 1; var n design reference; run;
Some of the results are as follows:
n Design Reference 72 2 ** 44 3 ** 12 4 ** 1 Orthogonal Array 72 2 ** 43 3 ** 8 4 ** 1 6 ** 1 Orthogonal Array 72 2 ** 37 3 ** 13 4 ** 1 Orthogonal Array 72 2 ** 36 3 ** 9 4 ** 1 6 ** 1 Orthogonal Array 72 2 ** 35 3 ** 12 4 ** 1 6 ** 1 Orthogonal Array . . .
The following statements illustrate one way that you can see all the designs in a certain range of sizes:
%mktorth(range=12 le n le 20) proc print; id n; by n; run;
The results are as follows:
n Design Reference 12 2 ** 11 Hadamard 2 ** 4 3 ** 1 Orthogonal Array 2 ** 2 6 ** 1 Orthogonal Array 3 ** 1 4 ** 1 Full-Factorial 14 2 ** 1 7 ** 1 Full-Factorial 15 3 ** 1 5 ** 1 Full-Factorial 16 2 ** 15 Hadamard 2 ** 12 4 ** 1 Fractional-Factorial 2 ** 9 4 ** 2 Fractional-Factorial 2 ** 8 8 ** 1 Fractional-Factorial 2 ** 6 4 ** 3 Fractional-Factorial 2 ** 3 4 ** 4 Fractional-Factorial 4 ** 5 Fractional-Factorial 18 2 ** 1 3 ** 7 Orthogonal Array 2 ** 1 9 ** 1 Full-Factorial 3 ** 6 6 ** 1 Orthogonal Array 20 2 ** 19 Hadamard 2 ** 8 5 ** 1 Orthogonal Array 2 ** 2 10 ** 1 Orthogonal Array 4 ** 1 5 ** 1 Full-Factorial
The %MktOrth macro can output the lineage of each design, which is the set of steps that the %MktEx macro uses to create it. The following statements illustrate this option:
%mktorth(range=n=36, options=lineage) proc print noobs; where index(design, '2 ** 11') and index(design, '3 ** 12'); run;
The results are as follows:
n Design Reference 36 2 ** 11 3 ** 12 Orthogonal Array Lineage 36 ** 1 : 36 ** 1 > 3 ** 12 12 ** 1 : 12 ** 1 > 2 ** 11
The design in 36 runs starts out as a single 36-level factor, . Then is replaced by . Finally, is replaced by , resulting in .