How do I display the total percentage and count together as a stacked bar chart without formatting all data to percentage values? - tableau-api

I asked this question (and this question) recently, and even though both have solutions, I am left with a new dilemma because each solution only works on an independent level (i.e. one solution won't work if the other solution is in place).
The problem is this: In Tableau, I discovered that by opting to display the data as a percentage of the total row value Analysis > Percentage of > Row, it resulted in the count value also being displayed as a number between 0 and 1 (i.e. percentage format, because of the aforementioned percentage-only setting).
Is there a way to achieve a 100.00% stacked bar which shows both percentage AND count, and which also isn't formatted to display all data as a percentage of the row total?
The screenshot shows what happens when both solutions are in place. Original screenshots are available within the body of each of the previous questions.
Note: I feel that the right way to go about it might be to normalise my data (bringing all values to a scale between 0 and 1), but being new to Tableau, I am not sure how this is achieved. If this is correct, I would appreciate a walkthrough.

Right click on the second SUM({Number of Records]) pill on the Label shelf, and clear the table calc. Edit your label if needed

Related

How to add the values of a binary dimension type column in a bar chart in SAP Analytics Cloud

I'm trying to put together a story and I'm starting to create the first pages with graphics. The graphs are based on tables that are in S4/HANA and have the format as shown in the first image but with more fields, in each line there are weeks (repeated, although they do not appear like that in the photo) and that week will have a condition; "SI" or "no".
When creating a graph I can represent the amount (y-axis) against the condition and the week (x-axis) and it would look like this (2nd photo). In addition to this, I would like to add another bar per week that represents the TOTAL, the sum of condition = "SI" and condition = "NO". Is it possible to do this from SAP Analytics Cloud or do I have to rack my brain changing the lines of the source table adding a total there?
As a clarification, I do not need to add 2 different numerical fields or anything, I would simply like to add the SIand NO of the condition column, if on the y-axis I put volume that represents volume and if I put amount that represents amount, but I am looking for a third bar With the total, I don't know if I explained myself well.
Thank you very much in advance, if you help me solve this I would be very grateful, greetings
https://ibb.co/dcCKKzF
https://ibb.co/kDN3ZXp

Birt Reports - Adding percentages to chart legend

Is it possible to add percentages to the chart legend, or is it the only way to put percentages to the chart, by adding the "Percentile Value Data"?
Thanks for your help in advance.
AFAIK the percentile value is usually something different, it only makes sense if the categories are based on intervals, e.g. given 7 billion living humans and measuring their age, the top 0.1 percentile are the 7_000_000_000 * 0.1/100 = 7_000_000 oldest living humans.
So, percentile values make sense for things you can measure, like age, income, length - in other words, numbers, or at least things which can be ordered.
You wouldn't use a pie chart then.
Percentile values don't make sense for things that cannot be measured like car labels.
Take a look at https://forums.opentext.com/forums/developer/discussion/48914/how-to-create-pie-chart-with-percentage-instead-of-values
M Williams writes there (I just repeat this here):
In the chart editor, you can go to the "format data" tab, then to the value series section, click on the "labels" button at the bottom, delete the "value data" option from the values window, then from the dropdown below the window, choose the percentage option and add it. This will show your pie chart labels in percentage.

How to make a stacked bar chart where the total measure is always fixed at 100%?

I am attempting to create a 100% stacked bar chart in Tableau where the total stacked measure is always equal to 100% on the axis in order to make a productivity dashboard. I want all filter options to look like the first picture attached below where the total stretches and stops at 100%. However, some cases break this rule, such as going over 100% or when the "All" option is selected and stretches it 700%.
I tried fixing the axis max at 100% and it works perfectly for all the individual employees but since the "All" selection goes up to 700%, it just shows it all the way full at 100%. Is there anyway to make my total measure, in this case "Goal", always set to 100% no matter what the number is? This is my current formula for my total measure of "Goal" {Fixed [Contractor], Date: SUM([Goal])} / {Fixed [Contractor], [Date]: SUM([Goal])}
Thank you for any help!
Employee 1 with normal productivity where the axis is staying at 100%.
Employee 2 going over 100% where the axis then stretches past 100%.
All employees added up where it stretches the axis to over 700%.
This is most likely a problem with the "Compute Using" attributes for the table calculation. Since table calculations are secondary calculations on top of your existing measures you have the flexibility for how they are calculated.
Here is how to adjust this. Click on your measure and select "Edit Table Calculation..."
To get the same result as you I will want the table calculation to calculate on "Table (across)" which will look at the dimension (in my picture, Category) instead of by Category AND Month. The little numbers in brackets and the yellow highlights are especially helpful in showing you how the calculations are being interpreted.
See the default "Table (down)" and the desired "Table (across)" calculations in the screenshot below. You will likely want the same but it might depend on your exact Viz setup.

Calculating % Complete

enter image description here
From the Image I need to calculate % complete for the order number 1.
Calculation for complete will be
(total number of points for status 'Delivered' / total number of points)*100
The value should be 57%
Can some one help with the calculated field?
Look at IIF in help files
SUM(IIF([Status]="Delivered",[Point],NULL)) / SUM([Point])
I assume your column named Order No. extends all the way down each row (i.e., each row should have a 1 as Order No. but the screenshot does not show that.
Also, the above only works if the status of "Delivered" is consistently cased, which it is not in the screenshot. If it is not consistently cased, wrap [Status] in an Upper function:
SUM(IIF(UPPER([Status])="DELIVERED",[Point],NULL)) / SUM([Point])
You can also get the effect you want, just by manipulating the Tableau user interface -- without needed to write calculated fields as #S. User18 showed. Both approaches work, but it helps to understand both alternatives.
As with #S. User18, I assume your column named Order No. is consistently filled in. I also assume [Order No.] is a dimension.
Place [Order No.] on a shelf, say Rows
Place [Status] on another shelf, say Columns
Place Sum([Point]) on a shelf, say Text
This shows the sum of the number of Points for each combination of the two dimensions: [Order No.] and [Status]
To convert the number of Points to a percentage, right click on Sum([Point]) on the marks card, and choose Quick Table calculation->Percent of Total
Similarly, right click on Sum([Point]) and experiment with different "Compute Using" settings to get the effect you want -- i.e. percent of each row, column, table etc. You can instead Edit the Table Calc if the preset Compute Using options don't get the effect you want.
Right click on any row or column headers that you want to hide - so if you only want to display the percentages for the Completed Status, hide the others. Don't exclude the others as that will change the calculations.
To understand more about Table Calculations, see the online help.

increase gap between bars in multi category groups

current imageI want to increase gap between bars in my SSRS bar chart after every group is finished (e.g. after every month). I have 2 category groups month and level. in each month there are 3 levels and I want to increase gap after 3 columns.
can you please help me?increase gap
There does not appear to be a way to increase the gap. However, there are two 'solutions'.
1. Go to the Chart Series Properties -> General -> Custom Attributes, and reduce the point width, perhaps from 0.8 to 0.6. Have a little play until you find something you like.
2. SSRS: Custom bar width between multi-level categories Try something like this. Add a dummy group to your dataset that has no value and turn the labels off.
I would go for number 1 as it is much simpler.