Routing is the process of determining a route through your survey. After asking the age of a person in question 1, you can decide what the next question has to be. If the age is more than 18, you can for instance go to question 2 about marriage and later skip question 3, otherwise skip question 2 and go to question 3 about toys. Tradionally routing is hard and leads to complicated graphs with many arrows and complicated if this, then that statements. Fortunately Limesurvey decided to stop using routing altogether from version 2.0 onward. Rejoice! We are using version 2.05. You will never, ever have to learn about routing.
Instead of routing (remember, routing is bad, complicated and error prone) Limesurvey uses the concept of Relevance. Relevance is good, trivial to use and can stop global warming, war and bad music. All you have to do is decide for each question wether it is relevant given the circumstances.
Now go back to our survey Family Life. Make a new question group called Marital Status. Add a question Are you married?. In the field Relevance equation type: age>17. Remember that age is the question code of a previous question.
Test the entire survey by clicking the gear icon in the survey toolbar. Try it twice. Once using 12 for age, once using 20 for age. Do you notice that the question about mariage is only asked if it is relevant? That is what the relevance field is all about. By default there is a 1 in this field. That means true. You can replace it with 0, which would make the question always irrelevant
It is essential that you put this question in a new question group. If the question about age would be in the same group as the question about marriage, then it cannot appear conditionally. It wil be there always or never. Question group do not change once they are shown on the screen.
To replace routing, more complex relevance equations are necessary too:
- You may want set two conditions to prevent certain people from entering your survey.
- age>17 && name!="Elizabeth Taylor"
- Or make exceptions to allow some to marry younger.
- age>17 || name=="Bo Derek"
Continue with the next lesson