This macro stores a cross tabulation of two data columns into the worksheet. It creates a bar chart of observed and expected counts for each cell, and a bar chart of contribution to chi-square for each cell.
Be sure that Minitab knows where to find your downloaded macro. Choose . Under Macro location browse to the location where you save macro files.
If you use an older web browser, when you click the Download button, the file may open in Quicktime, which shares the .mac file extension with Minitab macros. To save the macro, right-click the Download button and choose Save target as.
Suppose you want to store the cross tabulation of C1 and C2 in C11-C16 of the worksheet. You want to store the observed and expected counts in C6 and C7, respectively, and the cell labels in C4 and C5. To run the macro, choose and type:
%STXTAB C1 C2;
GCNTS;
GCHI;
STORE C11 - C16;
STLAB C4 C5;
STOBS C6;
STEXP C7.
Click Run.