Introduction
This article describes how to go from a standard crosstab or grid table...
...to a table that displays an Average of all the rows per column:
Method
1. Select your table.
2. In the toolbar go to Automate > Browse Online Library > Table Computations > Average of Each Column.
3. Select the Statistic to use (if different from the default).
4. Set the Position to place the new column on the top or bottom.
5. Press OK.
This rule adds an extra row to the bottom of the table which shows the Average of the statistics that are shown in the columns. Rows which are duplicates of other rows, for example the NET row, are not included in the computation of the average. Note, this rule can only apply to a single statistic and no significance tests are conducted on these averages.
Note, if you select Switch rows and columns on your table, the rule will no longer work due to the table dimensions changing. In this case, you will have to apply the Average of Each Row rule instead.
Technical details
Statistical tests are not performed on these cells. Averaging is not performed on the statistics shown in Statistics - Right.
How to apply this rule
For the first time in a project
- Select the table(s)/chart(s) that you wish to apply the rule to.
- Start typing the name of the Rule into the Search features and data box in the top right of the Q window.
- Click on the Rule when it appears in the QScripts and Rules section of the search results.
OR
- Select Automate > Browse Online Library.
- Choose this rule from the list.
Additional applications of the rule
- Select a table or chart that has the rule and any table(s)/chart(s) that you wish to apply the rule to.
- Click on the Rules tab (bottom-left of the table/chart).
- Select the rule that you wish to apply.
- Click on the Apply drop-down and choose your desired option.
- Check New items to have it automatically applied to new items that you create. Use Edit > Project Options > Save as Template to create a new project template that automatically uses this rule.
Removing the rule
- Select the table(s)/chart(s) that you wish to remove the rule from.
- Press the Rules tab (bottom-right corner).
- Press Apply next to the rule you wish to remove and choose the appropriate option.
How to modify the rule
- Click on the Rules tab (bottom-left of the table/chart).
- Select the rule that you wish to modify.
- Click Edit Rule and make the desired changes. Alternatively, you can use the JavaScript below to make your own rule (see Customizing Rules).