Using java script to rank results of formulas in a table (like literally the rank formula in excel) | XM Community
Question

Using java script to rank results of formulas in a table (like literally the rank formula in excel)

  • 26 October 2020
  • 2 replies
  • 20 views

Has anyone used custom java to create a rank formula (e.g., like in excel--- rank(cell, range))?
1) where do you paste custom script in qualtrics--- is it in the html tab on questions or somewhere else?
2) what would the custom script be?
I have 3 columns in a table with calculations of 2 rows (see below). The first row is a formula. The second row is where I would like the columns to be ranked (literally #1, #2, #3).
image.pngThanks so much!


2 replies

Userlevel 7
Badge +22

The custom javascript for a question is added under "Add javascript" option of the question. We can do the ranking logic using javascript and put the rank using in table using element selector.

Rondev,

Thanks- I am interested. What is the charge to do it?

Leave a Reply