This article describes how to create weights from variable(s) in Displayr. Weighting is a technique which adjusts the results of a survey to bring them into line with some known characteristics of the population. For example, if a sample contains 40% males and the population contains 49% males, weighting can be used to correct the data to correct for this discrepancy.
- One or more variables in your data set that you want to use to create weights. These variables can be categorical or numeric.
- The targets for each category in the weight variable. These can be percentages or population counts.
- Variables need to be single-choice. You cannot use multi-choice variables.
Specify a single adjustment variable
- Select Anything > Weight.
- Use the Adjustment Variable(s) box menu to select the categorical or numeric variable(s) you want to weight by. Then specify the Percentages for each category. Note that if your weight targets are percentages, the total must sum to 100. If you would rather use counts instead, use the pull-down menu to the right of Percentages to specify Population/Count:
For example, if your desired targets are 60% Male and 40% Female, you would specify:
Specify additional adjustment variable(s)
If you want to weight by more than one variable, click the Additional adjustment variable set tool and select the variable you want. For example, if you want to not only weight by Gender but also how frequently respondents drink coffee, do the following:
- Add the desired variable, which in this case is Coffee:
Combine categories in a weight variable
You can drag and drop categories for a variable to combine them for weighting within the weight tool. For example, in the Coffee variable, if you wanted to combine 4 of 5 days a week with Every or nearly every day, simply:
- Click the Every or nearly every day category
- Drag and drop it on the 4 to 5 days a week category.
Note: your percentages will revert to 0's when you drag and drop one category on another so you will have to specify them again if you haven't already.
Create two dimensional weights
Use the Adjustment Variable(s) box menu to the right of by to select additional variable(s).
For example, if you wanted to weight your data according to Income by Gender, you would specify:
Recompute weights for each category in another variable (e.g. wave data).
In some cases, it is desirable to calculate a weight based on group membership or time period. For example, in longitudinal studies, when the data is collected in waves, it is necessary to recompute the weight for each date period (week, month, etc.). By default, the weights are computed for the entire data set. This allows you to enter targets in terms of each month's sample, rather than the total sample. You may also select a Pick One question if the targets should be recalculated for each its categories (e.g. for each "wave" of a tracking study).
To recompute weights:
- From the Recompute Weights for menu, select the grouping variable. In this example, the variable is called Interview Date
As with all Q's weighting, the weights are recomputed whew data is imported, so this option enables the weighting to automatically compute new weights for new waves. This allows you to enter the targets in terms of each month's sample, rather than the total sample. You may also select a Pick One question if the targets should be recalculated for each its categories (e.g. for each "wave" of a tracking study).
Saving weight variables:
- Once you have an appropriate weight specified, on the bottom-right the button becomes active. Pressing this button takes you back to the main interface and you see the weight variable being added (saved) to the data set tree.
A variable is applied as a weight by:
- Selecting the object (e.g., page) to be weighted.
- Choosing the appropriate weight from Inputs > FILTERS & WEIGHT > Weight.
In order for a variable to be available as a weight, it needs to be set as Usable as a weight in the Properties tab of the Object Inspector.