Custom code to compute score | XM Community
Skip to main content
Question

Custom code to compute score

  • September 29, 2021
  • 1 reply
  • 28 views

Forum|alt.badge.img+1

I have an existing algorithm that computes class membership based on how people respond to 25 questions. Answers to each question are multiplied by a regression coefficient (specific to each question), and that total sum classifies into 1 of 6 classes. I am interested in having participants answer the 25 questions then automatically (either in the survey or afterward in an email) receive a notification of their membership. How might I go about doing this? Disclaimer: I am fluent in R and proficient in Python, but don't know any other languages.

1 reply

grahulp5
QPN Level 3 ●●●
Forum|alt.badge.img+13
  • QPN Level 3 ●●●
  • 238 replies
  • September 29, 2021

You can simply create embedded data in Qualtrics and use math operation to add/sub/mul the coefficients to the embedded and calculate the value for each of them.
Here is the link to get started with math operation.
Math Operations