Forum Discussion
How to display Text values on Bar chart?
- 5 years ago
Hi, Anonymous
As far as I know, this is impossible to achieve, the value has its own value attribute.
The bar graph itself cannot display text. The reason why I suggest you change your judgment condition to -1 is to keep the attribute of the value. The reason why it is -1 instead of 1 is because the custom formatting acts on positive, negative and zero values. Use -1 to distinguish it from the other two cases (1, 0).
According to your expectations, 1 and 1* are on the same horizontal line, which means that the value of 1* is 1. This cannot distinguish 1 from another 1. This is the purpose of -1. Once -1 is used, there are positive and negative axes, which cannot be avoided. Although the final result has a positive and negative axis, it better shows the actMonth.Glad to see different solutions.
Best Regards,
Community Support Team _ Zeon Zheng
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. - 5 years ago
Hi Anonymous ,
are you familiar with the External Tool Tabular Editor?
You need to download and install it first.
https://github.com/TabularEditor/TabularEditor/releases/tag/2.16.1
After the installation, you can start it from the menu bar.
Here you can create a Calculation Group (Table).
Here you create a Calculation Item.
Define the "Expression"
Define the "Format String Expression" and save the change
This solution is not yet optimal but a kind of proof of concept.
Hi Mwegner,
Thanks for the kind reply so far!
Actually I achieved Act & Plan bars as per your instructions.
Only two things to be resolved.
1. I'm getting Y-Axis scale has 1 and 1 instead 0,1,2...... As shown below.
2. I've a Italy data as below. and if you see 02 Plan records in June Month.
According the above screenshot expecting the below as output:
But at present I'm getting as below:
Looks like some where we need use Count Aggregation. I did see you used Max function.
I highly appreciated so far and I'm really looking forward to fix this. Thanks
Hi Anonymous ,
I have adjusted the Format String Expression for the Y-Axis.
VAR maxPlanMonth =
MAX ( 'Audit Fulfillment INT'[PlanMonth] )
VAR maxActMonth =
MAX ( 'Audit Fulfillment INT'[ActualMonth] )
RETURN
SWITCH (
TRUE,
maxActMonth = BLANK (), "0",
maxPlanMonth <> maxActMonth, "0*",
"0"
)
How should the counting be done if the rows would have to be formatted differently?