Forum Discussion
Scatter Plot measure not helping dynamic color..
Hi,
I have this table:
| Product | Month | Sales |
| A | 1 | 100 |
| B | 1 | 200 |
| C | 1 | 150 |
| A | 2 | 200 |
| B | 2 | 250 |
| C | 2 | 350 |
| A | 3 | 300 |
| B | 3 | 350 |
| C | 3 | 400 |
I have a scatter plot (which shows 'Sales' by 'Product'):
For the dynamic color of the dots, I have measures below:
The dots are all of the color green. However, when I change value of the variable pointing to "Measure 1", to a hardcoded vlaue, the color of the dots change in the scatter plot.
I believe the hardcoded value works as it is not impacted by context. How to ensure the first option (of leveraging Measure 1) works as expected as well?
I was exploring ways to present data an change the colors of the dots through Dax. The scatter plot as "sum of sales" on the X-axis and the 'Product' Name in the "Values" section.
I can see using 'Calculate', I am able to get the colors change according to the product choosen. So "Measure 1" is re-written as follows:
CALCULATE( SUM(Sheet1[Sales]) / DISTINCTCOUNT(Sheet1[Product]), ALLSELECTED(Sheet1) )
3 Replies
- Karthik50Frequent Visitor
Just to add some more info, I tried adding "Measure 1" as a columm and I got the below:
I think the context transistion is impacting the comparison....
- lbendlin
Super User
what's the reason for choosing a scatter plot? Where is your second value ?
- Karthik50Frequent Visitor
I was exploring ways to present data an change the colors of the dots through Dax. The scatter plot as "sum of sales" on the X-axis and the 'Product' Name in the "Values" section.
I can see using 'Calculate', I am able to get the colors change according to the product choosen. So "Measure 1" is re-written as follows:
CALCULATE( SUM(Sheet1[Sales]) / DISTINCTCOUNT(Sheet1[Product]), ALLSELECTED(Sheet1) )