This content describes Snap 11. For Snap 10, the equivalent page will be in Snap 10 help

Next Topic

Book Contents

Book Index

Example of setting up a variable for a complex filter

The following example assumes that it is regularly required to analyse survey data for the following groups: Males under 45, Males 45 plus, Females under 45, Females 45 plus. A variable can be set up to identify each group as a code thus making specification of the relevant filters quicker and easier.

  1. Click Variables window button to display the Variables window.
  2. Click New button to add a new variable.

  3. Specify the Variable Details. Each respondent will only fall into one of the new codes.

    Name: AgeGender

    Label: Age and Gender

    Type: Derived (the variable will derive its data from other existing variables.)

    Response: Single

  4. Specify the Code Details:

    Code

    Code Label

    Value

    1

    Males under 45

    Q9=(1~4) AND Q10=1

    2

    Males 45 plus

    Q9=(5,6) AND Q10=1

    3

    Females under 45

    Q9=(1~4) AND Q10=2

    4

    Females 45 plus

    Q9=(5,6) AND Q10=2

  1. Click Save button to save the variable.

You can now use the variable to filter data by age/gender groups when browsing or editing data.. For example males aged 45 plus can be identified using the filter AgeGender=2.

See Also

Using patterns in filters

Example of using case numbers in a complex filter

Finding errors