Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

How to use chr(32) in pie chart expression?

Hi all,

I have been trying to show values and it's relative percentage for a pie chart . I have used the below expression to show the count of values in legend

Count({<Rejoined={'N'}>}[Primary Reason])

and checked the Relative check box to get those values converted to percentages. But now the user requires, both the Integer values and its corresponding percentages to be shown in legend side by side. I have attached the screenshots of the integer and percentage values individually obtained.

Now the requirement is for example should be shown in legend as follows

Primary Reason

Better Opportunity          141     25.31%

I tried the below expression

Count({<Rejoined={'N'}>}[Primary Reason]) &' '& Count({<Rejoined={'N'}>}[Primary Reason])/Count(Total{<Rejoined={'N'}>}[Primary Reason])*100


and the result is


Primary Reason

Better Opportunity          14125.31

Please help me out in finding where and what I am doing wrong.

Thanks in advance.

1 Solution

Accepted Solutions
MK_QSL
MVP
MVP

Use below expression

Dual(Num(Count({<Rejoined={'N'}>}[Primary Reason]),'#,##0') & ' (' & Num(Count({<Rejoined={'N'}>}[Primary Reason])/Count(Total{<Rejoined={'N'}>}[Primary Reason]),'0.00%') &')',Count({<Rejoined={'N'}>}[Primary Reason]))

Tick Values on Data Point

View solution in original post

4 Replies
MK_QSL
MVP
MVP

Use below expression

Dual(Num(Count({<Rejoined={'N'}>}[Primary Reason]),'#,##0') & ' (' & Num(Count({<Rejoined={'N'}>}[Primary Reason])/Count(Total{<Rejoined={'N'}>}[Primary Reason]),'0.00%') &')',Count({<Rejoined={'N'}>}[Primary Reason]))

Tick Values on Data Point

Anonymous
Not applicable
Author

Thanks Manish.

That worked fine. One question though, is it possible to show the same on legend instead of the Data points?

MK_QSL
MVP
MVP

Most probably no

Anonymous
Not applicable
Author

Ok thank you anyways.