A LimeSurvey Solution for Linked/Dyadic Data Collection
I’d like to share a solution for collecting linked/dyadic data from a simple online survey. The following instruction is specific to the open-source LimeSurvey application, but could be used as a template for expansion to other survey platforms. Notably, LimeSurvey is free.
- First things first, you’ll need generate and save a random code somewhere your survey (I recommend adding this at the end).
- Create an “Equation” type question in LimeSurvey. LimeSurvey has a built in random number generator that you will call on using this question type.
- To implement and save a random code made up of four digits (1000-9999), two letters (lower case or capital), and finally one additional digit (all settings you can change), copy/paste the following text into the “Equation” style question:
- Under “Code” (i.e., the question title), enter “PIN” (you can change this to any name you’d like as long as you update the question syntax accordingly).
- Under “Question”, enter “{if(is_empty(PIN), join(rand(1000,9999), substr(“abcdefghijkmnpqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ”, -rand(1,48),1),substr(“abcdefghijkmnpqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ”, -rand(1,48),1),(SAVEDID)),PIN)}”.
- Under advanced settings, turn “Always hide this question” to “On” as respondents do not need to see the code in real time.
- You now have a random code (named “PIN”) generated and saved for survey responses. The next step is to collect information that will be used to contact respondents’ supervisors, spouses, or any other survey dyad. To do this, create three LimeSurvey questions following the “PIN” question in the prior step (order matters!). The three question codes, types, text, answers, and necessary survey logic/validation follow (feel free to customize to your liking). Take note of the Question Group IDs (if you use question groups) and Question IDs of the Name and Email questions as you will call on these later (as “[GroupID]” and “[QuestionID]” respectively).
- Permission
- Question Type: List (radio)
- Question Text: “Do we have permission to contact your [supervisor, spouse, etc.] to complete a follow-up survey?” [Expand with specifics regarding the additional survey and protections you will implement to safe guard respondents’ personal information]
- Answers: “Yes” (Code: “per01”) and “No” (Code: “per02”)
- Name
- Question Type: Multiple short text
- Question Text: “Please provide your first and last name:”
- Subquestions:
- “First” (Code: “name01”) and “Last” (Code: “name02”)
- Survey Logic to only display this question if permission is granted (enter the following under “Relevance equation”): ((Permission.NAOK == “per01”))
- Email
- Question Type: Short free text
- Question Text: “Please provide your [direct supervisor’s, spouse’s, etc.] email address:” [Expand with specifics regarding data integrity that you will implement. For example, “Do not complete the supervisor survey yourself. Only supervisors completing surveys from verified work email addresses and from unique locations qualify.”]
- Enter the following under “Validation” to require an email address: “/^(\w[-._+\w]*\w@
- Survey Logic to only display this question if permission is granted (enter the following under “Relevance equation”): ((Permission.NAOK == “per01”))
- Permission
- You now have everything needed to contact supervisors (or other linked respondents). You can use LimeSurvey Expression Manager syntax to call on the variables you created and LimeSurvey’s built-in notification feature to push out the linking survey email as respondents finish their survey. Do this as follows:
- Under “Surveys” click to select your survey (note the survey ID listed after your survey name). You will insert this where the template below calls for [SurveyID].
- Under the “Survey properties” drop down menu, select “Email templates”
- Now select “Detailed admin notification” (“Basic admin notification” could also be used).
- Craft the email you plan to have pushed out, calling on your previously selected variables. Below is a template you can modify:
- Subject:
- “[Your institution] Research for {INSERTANS:[SurveyID]X[GroupID]X[QuestionID][name01} {INSERTANS:[SurveyID]X[GroupID]X[QuestionID]name02}
- Body:
- “Dear [supervisor, spouse, etc.] of {INSERTANS:[SurveyID]X[GroupID]X[QuestionID]name01} {INSERTANS:[SurveyID]X[GroupID]X[QuestionID]name02},{INSERTANS:[SurveyID]X[GroupID]X[QuestionID]name01} is participating in research on [topic] being conducted at [your institution]. As his/her [supervisor, spouse, etc.] we would like your help completing a brief survey. [Additional text/protections as necessary. For example, “Please know that your response will be entirely confidential and your email address will not be kept on file. We will not contact you again.”]To provide your response, please visit this link [hyperlink to your second survey]. To link your response with {INSERTANS:[SurveyID]X[GroupID]X[QuestionID]name01}, you will need to enter the following unique code at the beginning of the survey (please copy and paste):Your unique code is: {PIN}Thank you!
[Your name]
- “Dear [supervisor, spouse, etc.] of {INSERTANS:[SurveyID]X[GroupID]X[QuestionID]name01} {INSERTANS:[SurveyID]X[GroupID]X[QuestionID]name02},{INSERTANS:[SurveyID]X[GroupID]X[QuestionID]name01} is participating in research on [topic] being conducted at [your institution]. As his/her [supervisor, spouse, etc.] we would like your help completing a brief survey. [Additional text/protections as necessary. For example, “Please know that your response will be entirely confidential and your email address will not be kept on file. We will not contact you again.”]To provide your response, please visit this link [hyperlink to your second survey]. To link your response with {INSERTANS:[SurveyID]X[GroupID]X[QuestionID]name01}, you will need to enter the following unique code at the beginning of the survey (please copy and paste):Your unique code is: {PIN}Thank you!
- Subject:
- Of course, you need to ensure your linked survey is set up in order to include its link in the email template above. You’ll also want to start that survey off with a question collecting (and validating the format of) the code the linked respondent should enter. The details needed to set up that question follow:
- Question type: Short free text
- Question Text: “Please enter the code from your invitation email.”
- Enter the following under “Validation” to ensure the code is a possible code based on the settings in this example (edit accordingly using LimeSurvey syntax if you changed the random code format): /^[0-9]{4}[A-Za-z]{2}[0-9]+$/
- Now all you need to do is set the “Detailed admin notification” to be sent to the supervisor’s email address (or other linked respondent). This is implemented as follows:
- Under “Surveys” click to select your survey.
- Under the “Survey properties” drop down menu, select “General settings and text”
- Expand “Notification & data management” and under “Send detailed admin notification email to:” enter {INSERTANS:[SurveyID]X[GroupID]X[QuestionID]}
Now you can collect dyadic data using LimeSurvey. Good luck and please share your experiences, improvements, extensions, and/or concerns.
Image credit: https://3.bp.blogspot.com/-V0cHqZl3fOA/VdUL4zegiNI/AAAAAAAABAM/oCmKZPukXsc/s640/APIM%2Bspecificis.png
So what are the benefits of LimeSurvey over Qualtrics? I imagine that a lot of these functions could be completed in Qualtrics (but you might have to pay for them). Just curious – as I have never used LimeSurvey before.
A big advantage is simply the open source status of LimeSurvey. In addition to not costing anything, it ensures accessibility (anyone can carry out what you share/develop). The expression manager and the ability to call on variables seems to me to have more useful applications than anything the major platforms offer (albeit, there’s a bit more of a learning curve). Finally, the survey logic procedures (e.g., showing one question based on another question’s response and more complicated extensions) are more full-featured than in Qualtrics (and, IMO, harder to set up wrong). Naturally a lot of it is preference. LimeSurvey’s open source status and feature-rich build are what do it for me.
Is there a way to give one member of the dyad a pin to give to their partner? That way the participants have one shared “PIN” number as a way to link responses?
Hi Brandi,
You bet! If I follow your question, providing a PIN is what possible and what is being described in this post (see the first two sections of the post). Feel free to send me an email if you need any further clarification.
Best,
Justin
Hi Justin, Is there a way to do this without using the survey respondent’s first and last name?
Hi Brandi,
If new dyad member (i.e., supervisor) is answering questions regarding the original dyad member, the new dyad member will need to know who it is that they’re answering questions about. You could use any unique identifier as long as the new dyad member is aware of the identifier, names are just the easiest unique identifier to use for example purposes.
Of course, if the dyad members are only answering questions specific to themselves, no name would need to be given.
Hope that helps,
Justin