Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

creating multiple HITs using a csv file

  • aminhosseiny
  • aminhosseiny's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
4 years 9 months ago - 4 years 9 months ago #192929 by aminhosseiny
creating multiple HITs using a csv file was created by aminhosseiny
I am trying to populate/import fields from a csv file (or XML, Excel, ...). I want to create Human Intelligent Tasks (HITs) outside the LimeSurvey, put them into csv file, and then pop them into a survey. Something like what the links below explained in the Amazon Mturk.
Code:
blog.clickdimensions.com/automate-your-data-work-with-amazons-mechanical-turk/
blog.mturk.com/using-csv-files-to-create-multiple-hits-in-the-requester-ui-22a25ec563dc
Last edit: 4 years 9 months ago by DenisChenu. Reason: Remove direct links
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team & Official Partner
  • LimeSurvey Community Team & Official Partner
More
4 years 9 months ago #192945 by DenisChenu
Replied by DenisChenu on topic creating multiple HITs using a csv file
Please : don't put link , just explain step by step what you try and where it don't work.

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member. - Professional support - Plugins, theme and development .
I don't answer to private message.
The topic has been locked.
  • aminhosseiny
  • aminhosseiny's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
4 years 9 months ago #192978 by aminhosseiny
Replied by aminhosseiny on topic creating multiple HITs using a csv file
I'll explain more.
Let's say each task (HIT) is a survey for five users, with a bunch of questions and fields to complete. In each task for example 3 fields are different and unique. We have tasks in csv file and want to import those unique fields to the survey. This is what I want to do with csv file. I used a toy example to explain this below.

Survey:
Read the article first. {$article_text}.
Read this sentence of the article: {$sentence_text}
based on the article, rate each description from 0-5:
Q1. {$desc1}
Q2. {$desc2}
Q3. {$desc3}

Csv file:
article_text,sentence_text,desc1,desc2,desc3
row1
row2
....
rown

As you can see, we have a unique set of tasks/questions/surveys that I can't enter manually because they are more than 500. Do you have any solution for that?
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 9 months ago #192986 by tpartner
Replied by tpartner on topic creating multiple HITs using a csv file
How do you define which row of the CSV to pull from?

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
  • aminhosseiny
  • aminhosseiny's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
4 years 9 months ago #192989 by aminhosseiny
Replied by aminhosseiny on topic creating multiple HITs using a csv file
Each row is one task for N users. For example Amazon Mturk, asks for number of users for each row, and then pull each row and make the survey based on that for next N users. It goes on, till each row will be shown to N users.
The topic has been locked.
  • tpartner
  • tpartner's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 9 months ago - 4 years 9 months ago #192991 by tpartner
Replied by tpartner on topic creating multiple HITs using a csv file
Well, I don't know anything about Amazon Mturk but within LimeSurvey you could use JavaScript to...

- Make an AJAX call to load the contents of the CSV into memory
- Use the jquery-csv parsing plugin to convert the contents into an array of arrays
- Select a specific item of that array (equates to a CSV row)
- Load hidden long-text and/or short-text questions with the items in that item (equates to the row cells)

Then you can use Expression Manager to pipe the values in the hidden questions into your ratings question(s).

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Last edit: 4 years 9 months ago by tpartner.
The topic has been locked.
Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose