How to reference a Typing Tool? | XM Community
Solved

How to reference a Typing Tool?


Userlevel 1
Badge +2
We have created a typing tool in excel that places respondents into 1 of 4 segments based on responses to a particular set of questions. It is very complex, so way too much to manually program in all the variations in the survey flow.

I was wondering if anyone had any ideas for how to have qualtrics reference this excel sheet in any way to automatically identify which segment the respondent has been placed into. The only thing I can think of is maybe using the "Web Service" capability in the survey flow, but I am not exactly sure how to create an external hosting page and/or how difficult that might be.

If anyone has any tips or thoughts, please let me know!
icon

Best answer by TomG 4 May 2018, 18:26

View original

3 replies

Userlevel 7
Badge +27
@GeoffK - You are on the right track. You would emulate the Excel formula(s) in a web service script. You can use any web scripting language - I recommend PHP. If you have programming experience, it shouldn't be difficult. You would pipe the answers from your set of typing questions as input parameters and it would return your segment as an embedded variable. You would need access to a web server that would host the script.

If you don't have a place to host a web script, an alternative option would be to use a JavaScript to emulate the Excel forumula(s) and store the result as an embedded data field or as an answer to the question.

Hi there - can you explain this in a bit more detail for someone who doesn't have any experience with webscripting/JavaScript?

Userlevel 7
Badge +27


https://www.qualtrics.com/community/discussion/comment/28884#Comment_28884You write a script that:

  1. Accepts the answers to the typing questions (probably the recodes) as inputs

  2. Using the inputs, calculates the segment using the same formulas you use Excel

  3. Outputs the segment so it can be saved as an embedded data field

I think a web service is preferable. You could write in in php or python and host it on a web server. The output should be in json format. Add a web service call to the script in the survey flow.
If using JavaScript, pipe the inputs into the script, do the calculations, and save the segment to an embedded data field. Define the embedded data field in the survey flow prior to question block containing the script.

Leave a Reply