Chaid Tutorial 1
Chaid Tutorial 1
Chaid Tutorial 1
0 USER'S GUIDE
The Data
In this tutorial, we will be using the SPSS file subscrib.sav, which contains information about a direct marketing promotion for a magazine subscription. Based on their response to this promotion, households were categorized as paid responders, unpaid responders, or nonresponders. Paid responders were households that returned a mail form, checked off the item that they would like to subscribe to the magazine, and later paid for the subscription. Unpaid responders were households that returned the form and checked off the item that they would like to subscribe to the magazine, but then cancelled their subscriptions prior to paying. Nonresponders includes all others (that is, households that did not request a subscription). Figure 1. Subscrib.sav file
The variables included in the file are: AGE GENDER KIDS INCOME age of head of household sex of head of household presence of children household income
presence of bankcard household size occupational status of head of household coded 1 for paid, 2 for unpaid responders and 3 for nonresponders. coded 1 for (paid and unpaid) responders, and 2 for nonresponders to be used as the dependent variable in this tutorial number of cases (designated as a case weight in SPSS)
The purpose of our initial analysis is to identify household segments that are more likely to respond than other segments.
Once you click on the file, the Model Analysis Dialog Box opens. It looks like this:
Figure 3. Model Analysis Dialog Box The variables in the data file subscrib.sav are included in the Variables List Box on the left, except for the variable FREQ. SI-CHAID automatically entered this variable in the frequency box because it was specified within SPSS to be used as a case weight when creating the SPSS save file.)
Assigning Variables
To begin a CHAID analysis, we need to select one (or more) dependent variables and at least one predictor. Optionally, one of two weight variables can be specified - a case weight (frequency) and a sampling weight (weight). For this analysis, the dichotomous variable RESP2 will be the single dependent variable. For an example of multiple dependent variables, see Tutorial #3 in this manual. To select the dependent variable: Click on RESP2 in the Variables Box. Click on "Dependent" to move RESP2 to the Dependent Variable Box
Next, we will select the predictor variables. The predictor variables for this analysis will be AGE, GENDER, KIDS, INCOME, BANKCARD, HHSIZE, and OCCUP. Highlight AGE, GENDER, KIDS, INCOME, BANKCARD, HHSIZE, and OCCUP. Click on "Predictors" to move the above variables to the Predictor Variable Box.
The completed Model Analysis Dialog Box should look like this:
After the data scans, the default combine types appear next to each predictor. The combine type specifies how the categories of the predictor are allowed to merge. You can change the combine type for a predictor from the Predictor Options tab or by right clicking on the variable and selecting the desired combine type name from the pop-up menu. Figure 5. Predictor Options pop-up menu
You may view category labels by selecting Details from this menu or by double-clicking on a predictor or the dependent variable name. This action brings up the category-labels window.
Setting Options
The Options Tab controls the operation of the CHAID segmentation algorithm, including the stopping rule and the minimum segment size. Click on the Options Tab to open the Options Dialog Box Double-click on the Depth Limit text box and enter 2 to set the analysis depth limit at 2. That tells SICHAID that the tree should expand to no more than two levels deep. Leave the other options, Merge Level and Eligibility Level, at their default levels. Select Auto in the Startup Mode Menu on the right. This tells SI-CHAID to run the analysis automatically.
Growing a Tree
After you have set all the options, you are now ready to grow a segmentation tree. Click Explore
SI-CHAID automatically prompts you to save the new model with a Save As dialog box. Figure 8. Save As Dialog Box
In the File Name box, type resp2 to override the suggested filename and click on Save. That tells SICHAID to save your analysis settings to an analysis file with the name resp2.chd. All printed and saved output will be prefixed by the name resp2.
10
By default, SI-CHAID displays the tree diagram in local mode. The local mode displays detailed results within each node, and numbers each terminal node. The results of the CHAID tree shows 6 segments, details for which are displayed in each of the 6 terminal nodes. The highest response rate is obtained from segment 2, defined as households of size 2 or 3 (HHSIZE = 2-3) and occupation = white collar (OCCUP = 1). Terminal node #2 shows that there are a total of 1,758 cases in this segment and the response rate is 2.39%. The next best segment is obtained from households containing 4 or more persons (terminal node #4), and the response rate for this segment is 1.92%. For large trees, all terminal nodes may not be visible at once. In this case, a global Tree Map view is useful to get a better feel for the entire tree. To switch to global mode, Click on Window Select New Tree Map
The Global Tree Window then appears Figure 10. Global Tree Window
Gains Charts
The results of a CHAID analysis can also be displayed in the form of Gains Charts, which sort all or a subset of the segments from best to worst and also provides cumulative results expected based on the best K of these segments (or best quantile). In our current analysis, best is defined based on the percentage of cases in the first category of the dependent variable (response rate). If the root node is the current node, the gains charts include all segments. If some other node is current, the gains charts are based on segments derived from the current node.
11
SI-CHAID displays a detailed gains chart, where the segments are listed from best to worst. Figure 11. Gains Chart
The column labeled Id contains segment numbers. The next column (size) contains the number of cases in this segment, followed by a re-expression of segment size in terms of a percentage (% of all). The 4th column (resp) contains the number of responders in the segment, followed by a re-expression of this quantity in terms of percentage. Thus, we see that segment 2 represents 2.2% of all cases, but accounts for 4.5% of all respondents. The next column displays the response rate for the associated segment (score). Thus, we see that segment 2 has the highest response rate (2.39%). The next highest response rate is 1.92% (segment 4). The score represents the mean category score. By default, the category scores are 1 for the first category, and 0 for all others, so that the mean score corresponds to the % in the first category (responders in this example). To change the category scores, right click on the gains chart to bring up the gains chart control panel.
12
Note that a check mark appears next to Responders to indicate that the default gains chart is presented. Click the Scores button, to bring up the gains chart category scores window. Double click the score you wish to change, enter the replacement score and click the Replace button. Click OK after all the new scores have been entered. To view the new gains chart based on the revised scores, click Responders in the Gains Chart control to remove the check mark for the default gains chart. Now click Responders once again in the Gains Chart control panel to restore the default gains chart.
The index column for a given segment measures the average response score for that segment relative to the average score for the total sample. The index score for segment 2 is 208, which is computed as (2.39% / 1.15%) x 100. This means that the response rate for this segment is 108% higher than average. Columns 8 through 13 in the gains chart present cumulative statistics. From the columns labeled Cum: size, % of all, and score, you can see that the three highest responding segments constitute 27.6% of the sample and have a combined response rate of 1.63%. The final column, Cum: index, measures the cumulative average response score for these segments relative to the average score for the total sample. For example, the index for the three best segments is 142 (1.63% / 1.15%). Thus, the three best segments, taken together, responded at a rate 42% higher than average. If you know the break-even response rate (or if the category scores reflect profitability), you can use gains charts to determine the segments to which you should mail future promotions. For example, suppose that when you take into account the cost of mailing and the gain from responders, you need a response rate of 1.45% to break even. Looking at the Gains chart above, (and assuming that this is your final segmentation), you would expect to make a profit if you mailed only the top two segments, since the score for the remaining households falls below the break-even level. Large savings could be gained by mailing only to segments with the highest response rates.
13
Figure 13. Summary Gains Chart The score column shows that, the predicted response rate would be 2.01% if the best decile were mailed.
A window appears containing SPSS if-then-else statements which compute the variable chdsegmt containing the CHAID segment number. Figure 14. Source File
Tables
The New Table Window option displays a table of the dependent variable (columns) by the current predictor variable (rows). You can control whether the table displays row percentages, column percentages, total percentages, or cell frequencies, and whether the table shows merged or unmerged categories of the predictor.
14
After-Merge Table
To view a table showing row percentages for merged categories of HHSIZE at the top of the tree: Click the top (root) node of the tree diagram Select Window Click on New Table
Values in the Respondent column match the values displayed in each of the four HHSIZE nodes:
Figure 15. After Merge Table Notice that SI-CHAID merged categories 2 and 3, as well as categories 4 and 5. The probability displayed in the bottom of the after-merge table, 2.7 x 10-15, is adjusted for the fact that categories have been merged. The probability used by CHAID to rank predictors is the smaller of this adjusted probability and the probability associated with the table computed before category merging.
Before-Merge Table
To view a row percentage table of HHSIZE by RESP2 for unmerged HHSIZE categories: Right-click on the Table to bring up Table Display. In the pop-up menu, click on Before Merge
15
SI-CHAID automatically produces a table of row percentages before HHSIZE categories are merged, as shown below:
Figure 17. Before Merge Table The table shows you the percentage of households in each HHSIZE category that responded to the promotion. For example, 1.09% of one-person households responded. Note that the total count in the lower right corner of the table (81,040) corresponds to the size of the highlighted node. The table also displays the probability value (p value), a measure of statistical significance. The smaller the p value, the more statistically significant the predictor. The p value for HHSIZE before categories are merged is 4.4e- 14 (shorthand for 4.4 x 10-14, a highly significant result). In fact, HHSIZE is the most significant of all the predictors. That is why the first split in the tree is based on household size categories.
16
To see why some of the categories of HHSIZE have been merged, compare the Before- and After- Merge tables. SI-CHAID merged two-person and three-person households because their before-merge response rates (1.49% and 1.59%) are not significantly different. The combined response rate for the merged categories is 1.52%. Similarly, SI-CHAID merges four- and five-person households, since the response rates for these subgroups (1.79% and 2.06%) are statistically indistinguishable. The combined response rate for the joint category is 1.92%.
Figure 18. Frequency Count Table The first row of the table indicated that 276 one-person households responded. The response rate displayed on the tree diagram (1.09%) is obtained by dividing the frequency by the total number of one-person households (25,384).
The Select Predictors dialog box will come up. Three predictors show up as offering significant splits of this subgroup. They are ranked from most to least significant. At this point you may a) split the subgroup using the best predictor (OCCUP), b) select one of the other predictors to split on, or c) change the Detail level display selection to include variables that are not significant in the list of predictors.
17
The tree now looks as follows: Figure 20. Tree Diagram with AGE used to Split the HHSIZE = 2-3 Parent Node
Rearranging Categories
Right click and select Rearrange Select the 5 age range categories between 18-64 as the 1st re-arranged category
18
Click Next Select age 65+ as the 2nd re-arranged category click the right arrow click next Select the missing age group Click the right arrow Click OK
Figure 22. Rearranged Tree Diagram SI-CHAID is designed as a useful tool to explore your data. There are no right or wrong trees. Feel free to explore your data as you wish.
19
2/9/05