I would propose to implement a feature "randomized conditions" (or something like that) in the survey setup. For example, there could be a dice symbol, and when you click on this symbol, you would see a numerical input field where you could enter the number of groups/conditions needed.
If you enter that the number of randomized conditions should be X, then a Javascript in the survey would be customized such that it creates a random number in the range of 1 to X.
If the survey is executed, then the script would create a random number in the range of 1 to X, and would enter the value of the random number into a column of the results table.
The script below has been proposed at the forums as a workaround to do just that. In the workaround, the script is inserted in a question, e.g., a numerical input question. This question serves to open a column in the results table where the value of the random number can be entered by the scipt.
$(document).ready(function()
var randNumber = Math.floor(Math.random()*X + 1);
$('input#answerSSSSXGGGXQQQ').val(randNumber);
);
(where X is the number of Conditions needed, SSSS is the survey ID, GGG is the group ID, and QQQ is the Question ID of the numerical input question that contains the script)
If the script is implemented in a survey desing feature rather than in a question, then the feature would have to create a question first, as a container where the value of the random number can be entered by the script.
The question that serves as a container for the random number should be hidden from survey participants. This is not currently possible to do in Lime Survey 1.90+ (see the following bug report:
http://bugs.limesurvey.org/view.php?id=4553)
However, at the forums I found two ideas how to hide a question without preventing autofilled entries.
Idea 1:
Re: Prefill hidden fields or (hidden questions)
In config-defaults.php:
$deletenonvalues = 1; // By default, LimeSurvey does not save responses to conditional questions that haven't been answered/shown. To have LimeSurvey save these responses change this value to 0.
Copy to your config.php and set to 0.
Idea 2:
Re:Prefill hidden fields or (hidden questions)
Or just hide the questions with CSS. Add the following to the end of template.css (or whatever your style sheet is):
Code:
div#questionQQ
display: none;
Where QQ is the question ID.
Assuming that we have created a random number with values from 1 to X, and have entered the value of the random number as an autofilled entry to a hidden container question, then we have assigned a kind of randomized group membership identifier to each participant (i.e., the value of the random number).
Now, the next thing needed is a display in the conditions setup that allows to select the hidden container question (which might be labeled "randomized conditions," for example). Further, the condition setup should allow to select different values of the random number as conditions for showing or hiding other questions. Optimally, the X possible values of the random number would appear as predefined answers in the conditions setup.