Numbering weighting axes
Each weighting axis must have a number by which Quantum can refer to it. Type the statement:
wmnumber=axis_name
at the top of the tabulation section under the a statement. If weighting is defined in the sex axis, you could write the wm statement as:
wm1=sex
If you use the weighting axis as the rows, columns or higher dimension of an unweighted table the weighting specifications are ignored. For example:
wm1=sex
tab sex region
tab sex region;wm=1
l sex
n10Base
n01Male;c=c110'1';wtfactor=48
n01Female;c=c110'2';wtfactor=52
l region
col 123;Base;North;South;East;West
This specification produces two tables. The first is unweighted so the weighting information in the sex axis is ignored:
| Base | North | South | East | West |
Base | 17 | 5 | 4 | 4 | 4 |
Male | 10 | 4 | 1 | 2 | 3 |
Female | 7 | 1 | 3 | 2 | 1 |
The second table has the same rows and columns but the cell values are weighted using the weights in the sex axis:
| Base | North | South | East | West |
Base | 844 | 244 | 204 | 200 | 196 |
Male | 480 | 192 | 48 | 96 | 144 |
Female | 364 | 52 | 156 | 104 | 52 |
Quantum does not accept a weighting axis as the rows or columns of the table if the table itself is weighted using a different axis, as in the example shown here:
wm1=sex
tab region brand;wm=1
l region
n10Base
n01North;c=c115'1';wttarget=100
n01South;c=c115'2';wttarget=110
n01East;c=c115'3';wttarget=120
n01West;c=c115'4';wttarget=115
To alert you to this error Quantum issues the message ‘weight line needs one target or factor’ for each element in the row or column axis (in this example, for each region).
See also