Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello all,
I would like to ask you if there is a way to get value from the chart.
As you can see on screenshot, I need that red and green value.
To calculate those in load script is not possible, since data in that chart is divided in several tables.
Is there a way to store those values in variables, and use them for some other calculations?
Best regards
Yes, Using TOTAL Keyword in your expression
Yes, use the expression from the chart in a text object, or pre-calculate it in a variable and you'll get the total.
There is a difference between...
Let vBonus = '=sum(Bonus)';
and
Let vBonus = 'sum(Bonus)';
...in a variable (above shows how to write them into your script, you could just do this in the variable overview instead, CTRL + ALT + V). If you use the equals, you'll get the value and if you put that in a chart it'll show the same value all the way down, however the one without the equal will write that expression and calculate a different value for each row.
To reference the variable elsewhere use
$(vBonus)
You could do other calculations like variance in your chart.
sum(Bonus)-$(vBonus)
...would give you the variance versus the overall total.
Hope this helps.
Sam
May be something like this
Sum(Aggr(YourExpression, YourDimension))