Embedded data math operation help | XM Community
Skip to main content
Hello all -

I have a survey that needs a report generated which can display percentages of a total - so, our respondents answer how many students are in a space, the number active, the number active on a playground feature, and the number sedentary. To display this data in my reports-reports, I set embedded data in the survey flow as follows (this is one of three - 'the number active'):

First, I created the variables to give me the 'percent' of how many were active of the total in the pre test and post test:
Percent_Active_PRE = $e{ ( q://QID14/ChoiceTextEntryValue / q://QID13/ChoiceTextEntryValue ) * 100 }
Percent_Active_POST = $e{ ( q://QID33/ChoiceTextEntryValue / q://QID32/ChoiceTextEntryValue ) * 100 }

Then, I created a variable in a separate embedded data box to calculate the difference between the variables I created above:
Percent_Active_Diff = $e{ ( ( q://QID33/ChoiceTextEntryValue / q://QID32/ChoiceTextEntryValue ) - ( q://QID14/ChoiceTextEntryValue / q://QID13/ChoiceTextEntryValue ) ) *100 }

I also created a variable to calculate that same difference in a different way:
EMB_Percent_Active_Diff = $e{ e://Field/Percent_Active_POST - e://Field/Percent_Active_PRE }

However, none of my embedded data is displaying in my report:
!

I'm at a loss - I've checked my math operations, I've cleared my cache and cookies, and nothing works. I've contacted Qualtrics and they have no solution.

I would appreciate any suggestions on what I may be doing wrong or what is happening with my data. Thank you!!

The embedded data in my survey flow:
!
@Liz2006 stupid question. Did you put the embedded data in the very end of the survey flow?

Is it only missing from the reports? Does it show in the Data&Analysis tab?
@Mslreen yes the embedded data is at the end of the survey flow. I only have one block in the survey.

No data displays for these embedded fields in Data&Analysis, either. So that leads me to believe there's something wrong with the math operations in the survey flow, but I can't figure out what.

Thanks for your response.
@Liz2006 You can't have spaces in math operations. Get rid of your spaces and try that 🙂
@Kate - which spaces specifically?

All of the guidance from Qualtrics uses spaces and math operations I've built in other surveys work with spaces. I'm a little confused here...
https://www.qualtrics.com/support/survey-platform/survey-module/editing-questions/piped-text/math-operations/
Huh- that's weird. All my math equations have no spaces. I had testing issues until I removed all of them. These work for me great.

!
@Liz2006,

They generally look correct to me. In Percent_Active_Diff you are missing a space between the * and 100, and in EMB_Percent_PSactive_Diff you have a double underscore Percent_PSactive_Diff.

I would create a block with a Descriptive Text question where you pipe all the inputs and all the results. Maybe your input pipes are wrong.
@TomG Thanks for catching those typos. I've fixed them, but that still hasn't fixed the issue. I'm really at a loss.

I checked all of the inputs, and they're correct. I've also made sure that all variables were set to number.

Anybody have suggestions for anything else I should double check?
> @Liz2006 said:
> @TomG Thanks for catching those typos. I've fixed them, but that still hasn't fixed the issue. I'm really at a loss.
>
> I checked all of the inputs, and they're correct. I've also made sure that all variables were set to number.
>
> Anybody have suggestions for anything else I should double check?

Make sure QID13 and QID32 aren't zero...that would cause a divide by zero error.
Hi @Liz2006 ! If you have not yet already, we’d recommend reach out to the Support Team, as they are best equipped to troubleshoot and dive deep into this with you!
Thanks, @ChristianB, I actually tried that first and the support person just kept telling me that it was working on their end and they did not offer any solution. That's when I decided to bring it to this forum.

Hello everyone, I need some help, I am not sure where, but I would say is implement math formula, piped text and branck logic for a decision making game.

 

The experiment is a game of financial decisions, there are two conditions, low scarcity and high scarcity, participants will be presented 10 products of services and they need to choose how they are oging to pay for it. At the high scarcity condition we give participants a Budget of $400 and another $ 200 every round. At the low scarcity condition we give participants a Budget of $800 and another $ 400 every round. Participants can pay in three conditions: 2 installments, 6 installments, or skip the purchase. At every round the participant needs to know what is the current Budget (remaining Budget from previous round + the added Budget - the outstanding installments) and the outstanding installments

 

At the end of the game they will have a Financial Health Score such as:

  1. current_budget >= 600 && total_purchases >= 5 "Excellent Financial Stability"
  2. current_budget >= 400 && current_budget < 600 && total_purchases >= 4 "Moderate Stability"
  3. current_budget >= 200 && current_budget < 400 && installments_due > 300        "At Risk" current_budget < 200 && installments_due > 400 OR budget < "Overleveraged – Financially Unstable"

 

I have reviewed the instructions on MATH OPERATIONS, PIPED TEXT, EMBEDDED DATA, and BRANCH LOGIC. I implemented the survey accordingly, but it is not working, and I'm not sure why. Qualtrics support was unable to resolve the issue.

Can someone help me?

 

 


Thanks, @ChristianB, I actually tried that first and the support person just kept telling me that it was working on their end and they did not offer any solution. That's when I decided to bring it to this forum.

The same is happening to me….exaclty the same, I need to dysplay results in each block (round) or my survey, I have been talking to Qualtrics for over a week now. None of their instructions work. I have read all instructions, even asked ChatGPT, but no solution. I am at lost here too. If @qualtrics cannot provide this kind of support, and we have to figure it out how it works, what is the purspose of it? 


@Liz2006,

Not sure if this would make any difference, but for one of the fields, try changing the field type from number to the default one(I guess textset). See if this works for 1 math operation.


Leave a Reply