Extract randomization information from text items

More
6 months 1 week ago #185034 by Lowhy22
Dear Community,
I am a Tutor for a psychology course and this semester we conducted several online studies using LS. One of the groups was using the rand(1,4) command in an equotation item to randomize between different text items, which were displayed to the participant (1 out of 4).
So the problem now is the already recognized issue that the rand() command without additional commands does not always match the number with the selected item as described here www.limesurvey.org/forum/design-issues/8...y-using-rand?start=0 .
The additional problem is now, that the group used text items which require no input from the participant and thus we can not see which item was selected for the participant.
Do you know any way how we can extract what text item the participants have seen? Because otherwise the whole study is kind of garbage :(.
We already looked at the times recorded, but they were only times for the question groups, not the questions itself.
I attached the survey structure if this is of any help. We are using Version 3.16.1+190314.

Thank you so much for any help!
Attachments:

Please Log in or Create an account to join the conversation.

LimeSurvey Partners
More
6 months 1 week ago #185053 by holch
You posted a survey with 29 questions...

We are doing this in our spare time and it would take quite some time to go through the whole survey to find where your problem lies. Which are the relevant questions?

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds
The following user(s) said Thank You: DenisChenu

Please Log in or Create an account to join the conversation.

More
6 months 1 week ago #185054 by holch
I think I found where your problem is. "Kommentar".

But I don't see where your problem is. The random number is saved in "zufall1". Depending on what is written there (can only be 1,2, 3 or 4) the respective text is shown. So if in your table the value of "zufall1" is 3, you know which text they should have seen.

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Please Log in or Create an account to join the conversation.

More
6 months 1 week ago #185057 by Lowhy22
Dear Holch,
thank you so much for getting back to me so quickly and I apologize for not being precise.
As you rightly guessed it is about the Kommentar question group.

The problem is that the randomly generated number from the equotation does NOT match with the selected text file.
So for example if the rand () command generates the number 3, it happens that the selected comment is NOT the comment which has zufall1 == 3 in the relevance equotation.

As I said before the problem is known and it has delt with before www.limesurvey.org/forum/design-issues/8...y-using-rand?start=0 by adding some expressions to the command in the equotation variable.

But the Problem we have now is that we already have gathered our data with the existing survey structure. And that leads me to my question if there is any other way to check which comment was selected and shown to the each participant? (since the output of the zufall1 equotation variable is not reliable)

Thank you again for you help I hope I made my problem understandable?
Best regards

Please Log in or Create an account to join the conversation.

More
6 months 1 week ago - 6 months 1 week ago #185058 by Joffm
Hi,

IMO this is normal behaviour.
The rand-function is always rendered when the page loads. (and when it is called)
Therefore we use this construct "if randomnumber still is empty, create a new one, else keep the old value".

So for example if the rand () command generates the number 3, it happens that the selected comment is NOT the comment which has zufall1 == 3 in the relevance equotation.

Where did you check the random number? Did you display this question? Or in the dataset?
If you compare with the displayed one, sure it will be different. As I said, it is always recalculated when called.

I made a few tests (10) and compared the displayed message with the stored random number.
It always was the correct one.
So you have to do, what was missed at the beginning - testing.
And not only that the survey works, but that the stored results match the entered values.
If none of the tests fails you are lucky; otherwise ...

BTW:
Why are there values in the "randomization group name"? This is used for something different (when you want to display questions in randomized order)
I removed them.

Best regards
Joffm


Volunteers are not paid.
Not because they are worthless, but because they are priceless
Last edit: 6 months 1 week ago by Joffm.

Please Log in or Create an account to join the conversation.

More
6 months 1 week ago #185065 by holch
I actually think the problems they have in their study does not come from the random generation, because from what I see (they don't allow to go back), the problem of rand(1,4) doesn't really apply here. Chances that the random number is triggered a second time after showing the comment should be close to zero.

The bigger problem is that comment 1 and 4 seem to be in the same randomization group, which can cause weird behavior. Overall, I think the survey is so messed up, because of this randomization group error, not because of the equation with the random number generation.

As Joffm said, this should come up during testing before field start.

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Please Log in or Create an account to join the conversation.

More
6 months 1 week ago #185073 by Lowhy22
Thank you very much for your quick reply. As I tested again the created rand number does not correspond with the selected comment, also in the data file.

Is there any other possibility to trace back the selected comments?

Best regards!

Please Log in or Create an account to join the conversation.

More
6 months 1 week ago #185093 by holch
If this is the case, there is no way to know which text has been displayed. However, the questions about the comments (at least for the first 2, the other two didn't have any text) are so basic, you should be able to know from the responses to the answers which text has been shown.

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Please Log in or Create an account to join the conversation.

More
6 months 1 week ago #185095 by Joffm
Just to add:
The random number changes if it is in the same group and displayed "group by group".
A month ago there was this same problem that I had to split my "beautiful" function into three parts.
https://www.limesurvey.org/forum/can-i-do-this-with-limesurvey/118275-children-randomization

See here:
Above the random number that is generated by the equation question
Below the random number that is generated again because of the call in the relevance equation.
This one is used to display the message.
Example 1:


Example 2:


Volunteers are not paid.
Not because they are worthless, but because they are priceless
Attachments:
The following user(s) said Thank You: holch

Please Log in or Create an account to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now
Join our Newsletter!