Solved
Math operation with Embedded data
Hi! I created a JavaScript to show a random value at the respondent and then stored that value (e.g. 0.5). I used the following java-script:
Qualtrics.SurveyEngine.addOnReady(function() {
var words = [0.50, 1.50, 3, 5]; //Your words
var i = Math.floor(Math.random() * words.length); //randomly select an index
var my_word = words[i]; //select a word
Qualtrics.SurveyEngine.setEmbeddedData( 'word', my_word); //Send the word to the Qualtrics output, otherwise you would not know which participant get which word
document.getElementById("random").innerHTML = my_word; //show the word to respondents
});
Now I would do a maths operation with the stored value (e.g. 0.5) plus a fix value (e.g. 3) and show it in a question. For example, I would have the following question:
If you said yes to the question above, (where showed 0.5 - ${e://Field/word} )
are willing to pay £ 0.5 + 3? (I want to show that maths operation automatically)
How can I do this? With Javascript or Piped Text?
Best answer by valedigen
I found it using Piped text! It was a syntax issue: $e{ e://Field/word + 3 }
Now it works!
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.

Importable Survey Example attached