Forum Discussion
How do I create a pie chart from a single column of data?
- 9 years ago
In this case, we can create another custom field using DAX and use that as legend. here is the sample:
Sample Data:
Output:
DAX Formula for new field:
EmailGroup = if(Table1[Email]=BLANK(),"Blank Email", if(Table1[Email]="NULL", "Email is Null", if(IFERROR(SEARCH("@",Table1[Email]),-1)=-1,"InValid Email", "Valid Email")))We can always change that formula on business need, it is just an example.
In this case, we can create another custom field using DAX and use that as legend. here is the sample:
Sample Data:
Output:
DAX Formula for new field:
EmailGroup = if(Table1[Email]=BLANK(),"Blank Email", if(Table1[Email]="NULL", "Email is Null", if(IFERROR(SEARCH("@",Table1[Email]),-1)=-1,"InValid Email", "Valid Email")))
We can always change that formula on business need, it is just an example.
- carlosDash9 years ago
Advocate V
Fantastic! This did the trick, thank you very much for taking the time to write everything in such detail :heart:. I had a little bit of trouble with the value separators (you used comma, but apparently due to localization I needed to use semicolon instead), but it works.
- parry2k9 years ago
Super User
Thanks for the feedback and good to know it is working for you.