I have programmed the random selection of a person, but if I save partially and retake the survey later, the person changes, how can I keep the name or order?
I have tried using variables and conditionals, however the compiler shows me circular references error.
In CSPro it is simple, in a variable if there was no answer the value was saved, and it cannot be changed, but in Survey Solutions I cannot find a way to establish this same control.
Thanks for the help.
if I save partially and retake the survey later, the person changes
This shouldn’t be the case. But it is not clear what it means “I have programmed the random selection of a person”. What is the exact syntax you’ve used. What is the minimal example that demonstrates the problem?
Copy selection of
“Public example Random Demo”
My questionnaire has 4 sections, in section 2, I select the person who answers section 4.
If I keep partial, in the next session the person changes.
I need to store the order, name of the person and it is not modifiable.
In CSPro I do it like this.
- I define seed.
- I generate random numbers for each person.
- I go through the list to determine who is selected, the pointer is the row.
- in a variable I store the pointer like this.
if special ($) then
$ = pointer;
This variable stores the data and cannot be changed.
How can I do something similar in Survey solutions?
the image show the change, it’s the same survey.
This is a good starting point. To address your concern I:
- have taken this questionnaire;
- imported it to the public demo server;
- created an assignment;
- created one interview, saving it before completing.
- Reopened it 20 times.
On all occasions the same person was remaining selected: “Sergiy”.
Interview key: 20-80-88-92
Hence, I can’t reproduce the problem based on your description.
Please provide more details.
I see the detail.
If I run the form from the server the selection remains, if I run from a scenario the data changes.
I have an other question,
In CSPro I can protect questions after entering the data and I use it to protect the selection.
How can I control that they do not change the number of people, the name or the order in the list, because this causes the selection to change.
The questionnaire is CATI, but if the selected person is not in the home, we want to control that the interviewer does not change the order of the people on the list, as that suits their convenience.
No matter how many calls must be made, we care about the rigor of the selection.
Thank you Sergiy
this is because the initial random value will be different for different scenario realizations.
It is important that you describe the issue well with as much detail as possible.
I hope to illustrate well the situation that I want to control:
The interviewer contacts the home, the survey is answered by Mary.
You must select a person who answers another section, the household list is:
Jhon, Head of the household
Gabriel, son (system selects row 3)
The system selects Gabriel, but I can exchange the names Gabriel and Sergiy, the system saves the order of the selected person, but not the name.
How can I save the person’s name or block the list, so that the line people are not changed.
Another way of looking at the situation is:
For a question of any kind, how to store the information so that it cannot change later.
This is different from preloading data.
The example on random selection that you’ve reused for this project was selecting a person at random position in the roster list. So by definition it will suffer from the disadvantage that once you know the position which will be selected - you will be able to rotate the list in a ‘desirable’ way.
I’d recommend a paper (original or one of a number of reprints):
Leslie Kish (1949) “A procedure for objective respondent selection within household”, Journal of American Statistical Association, 44, 380-387.