The %MktBIBD autocall macro finds balanced incomplete block designs (BIBDs). A BIBD is a list of treatments that appear together in blocks. Each block contains a subset of the treatments. BIBDs can be used in marketing research to construct partial-profile designs. The entries in the BIBD indicate which attributes are to be shown in each set. For example, a BIBD could be used when there are attributes or messages (treatments) and are shown at a time. A total of sets of attributes (blocks) are shown. BIBDs are also used in marketing research to construct MaxDiff (best-worst) designs. In a MaxDiff study, subjects are shown sets (blocks) of messages or product attributes (treatments) and are asked to choose the best (or most important) from each set along with the worst (or least important).
Note: The version of the %MktBIBD macro that is documented here requires SAS 9.01 or any subsequent release. An enhanced version of the %MktBIBD macro is included in the SAS 940m3 maintenance release. The enhanced version requires SAS 940m1 or any subsequent release. The documentation for the enhanced version of the macro is published at http://support.sas.com/rnd/app/macros/MktBIBD/mktbibd.htm.
The parameters of a BIBD are as follows:
specifies the number of blocks. In a partial-profile design, this is the number of profiles. In a MaxDiff design, this is the number of sets.
specifies the number of treatments. In a partial-profile or MaxDiff design, this is the total number of attributes or messages.
specifies the block size, which is the number of treatments in each block. In a partial-profile or MaxDiff design, this is the number of attributes or messages that are shown at one time.
If and are integers, and and , then a complete block design might be possible. This is a necessary but not sufficient condition for the existence of a complete block design. If and are integers, and and , then a balanced incomplete block design might be possible. This is a necessary but not sufficient condition for the existence of a BIBD. You can use the macro %MktBSize to find parameters in which BIBDs might exist. The %MktBIBD macro uses PROC OPTEX and a computerized search to find BIBDs. It does not have a library of BIBDs or use combinatorial constructions. Hence, it does not always find a BIBD even when one is known to exist. However, it usually works quite well in finding small BIBDs or something close for larger problems.
%MktBIBD(B=b, K=k, T=t <, optional arguments>)
You can specify either of the following to display the option names and simple examples of the macro syntax:
%mktbibd(help) %mktbibd(?)
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 following invocation of the %MktBIBD macro generates a BIBD design that contains blocks, treatments, and treatments per block:
%mktbibd(b=10, t=5, k=3, seed=104)
Figure 1 displays the design information. The block design efficiency of 100 indicates that the %MktBIBD macro found a BIBD. In many cases, it finds a design that is close to a BIBD, but each of the pairwise frequencies is not constant. For many marketing research problems, this is good enough.
Figure 1: BIBD Description
Figure 2 shows the treatment by treatment frequencies. Each of the treatments occurs exactly six times in the design, and each treatment occurs together with every other treatment three times.
Figure 2: Treatment by Treatment Frequencies
When the %MktBIBD macro makes a BIBD, it tries to optimize the treatment by position frequencies. In other words, it tries to ensure that each treatment occurs in each of the positions equally often, or at least close to equally often. Figure 3 shows the treatment by position frequencies, which are perfect for this design.
Figure 3: Treatment by Position Frequencies
Figure 4 shows the design.
Figure 4: Balanced Incomplete Block Design
Every BIBD also has a binary representation, or incidence matrix, with rows and columns and ones that indicate which treatments appear in each block. The %MktBIBD macro saves the incidence matrix in the OUTI= data set (which is named Incidence
by default). The following statements display the incidence matrix:
proc print data=incidence noobs; run;
Figure 5 displays the results.
Figure 5: Incidence Matrix
You can also view the BIBD arrayed as a block by treatment factorial design. By default, the %MktBIBD macro saves the design matrix in a data set named Factorial
. The following statements display the first 9 (out of 30) observations:
proc print data=factorial(obs=9) noobs; run;
Figure 6 displays the results.
Figure 6: BIBD as a Block by Treatment Factorial Design
The following invocation of the %MktBIBD macro generates a BIBD that has nondirectional row-neighbor balance:
%mktbibd(b=14, t=7, k=4, options=neighbor, seed=104)
Figure 7 displays the results.
Figure 7: BIBD with Nondirectional Row-Neighbor Balance
The resulting design is a BIBD, where each of the seven treatments appears in each of the four positions within a block exactly twice. Furthermore, the row-neighbor frequencies show that each of the pairs of treatments occurs exactly twice. The pairs in this design are , , , , and so on. The order of the treatments in each pair is ignored. Hence, in this design, with the nondirectional row-neighbor balance, the 2 followed by 5 in the first row of the design is treated the same as the 5 followed by 2 in the second-last row of the design. Usually this design is easily found in a few seconds. The last line of the first table ("Row-Neighbor Frequencies Optimized? Yes") along with the constant row-neighbor frequencies shows that perfect row-neighbor balance was achieved.
The following finds a BIBD that has row-neighbor balance, where the order of the treatments does matter, by specifying OPTIONS=SERIAL:
%mktbibd(b=14, t=7, k=4, options=serial, seed=361699)
Figure 8 displays the results.
Figure 8: BIBD with Directional Row-Neighbor Balance
When OPTIONS=SERIAL, the row-neighbor frequencies appear both above and below the diagonal. Each pair of treatments occurs exactly once. In this design, which has the serial (directional) row-neighbor balance, the 2 followed by 5 in the first row of the design is not treated the same as the 5 followed by 2 in the ninth row of the design.
An OPTIONS=SERIAL design is usually much harder to find than an OPTIONS=NEIGHBOR design. In this example, a random number seed that is known to produce an optimal design quickly was chosen. You usually have to run the macro more than once or change some options (such as the time value in the POSITER= option) and iterate for up to a few hours to find an equivalent design.
The following invocation of the %MktBIBD macro requests the same design but specifies a different pseudorandom number seed:
%mktbibd(b=14, t=7, k=4, options=serial, seed=104)
Figure 9 displays the results.
Figure 9: BIBD with Directional Row-Neighbor Balance
The following requests a design where it is not possible to have constant frequencies in the row-neighbor frequencies matrix:
%mktbibd(b=7, t=7, k=4, options=serial, seed=104)
Figure 10 displays the results.
Figure 10: BIBD with Unachievable Directional Row-Neighbor Balance
The %MktBIBD macro reports that the row-neighbor frequencies are optimized because a mix of zeros and ones with no twos or larger values is optimal for this specification. However, the nonconstant frequencies indicate that row-neighbor balance is not possible for this BIBD.