9 Replies Latest reply on Dec 30, 2017 8:13 AM by Nicole Klisch

# Visualization of colored values concerning True/False

Hey Tableau Community,

i want to visualize the tracking of the delivery of suppliers.

I want to automatize the evaluation. This is what i do now in excel. I count the total number of deliverys. Then i filter for the check in (false) to count the amount and then i filter the check out (false) to count the amount. Afterwards i put the numbers in the table.

For example For Building 1 its 9 from 10 are wrong for check in and 10 of 10 for check out are wrong.

I guess Tableau can be very helpful for this.

First i filtered by the days (for one week) because we do it for each week.

The check in & check outs are boolean. thats the reason why I counted the true and false of both (check in & check out) with Count(number of records).

The total number of deliverys, i calculated with Total(SUM([Number of Records])) which also worked but unfortunately it changes when i change the filters of checked in/ checked out. I would like that the total delivery number is always the same for the week. (1st problem)

The Count(number of records) gives me also a wrong output.

It says for Buidling 1:

Check in (True) & check out (false) = 1

Check in (false) & check out (false) = 9

Normally it should show me: Check out (false) = 10 and Check in (false) = 9. (please see pictures)

For the percentage i used (Count([Number of Records])/([Total Delivery's])) and for the coloring

If [percentage] < 75.00 then "red"

ELSEIF [percentage] > 75.00 then "yellow"

ELSEIF [percentage] = 100.00 then "green"

END

And unfortunately it does not work. I cant find the failure. Maybe it does not work with Tableau??

Could anybody help me out in this issue and explain to me what i do wrong?

Best regards

Nicole

• ###### 1. Re: Visualization of colored values concerning True/False

Hi Nicole - Can you share a sample of the dataset? I'm pretty sure you'll have to use Fixed (LOD expression) but difficult to make suggestion without looking at the data structure/granularities.

• ###### 2. Re: Visualization of colored values concerning True/False

Hey Manish,

sure. Please find attached the workbook.

• ###### 3. Re: Visualization of colored values concerning True/False

Good morning

and it now works

Jim

If this posts assists in resolving the question, please mark it helpful or as the 'correct answer' if it resolves the question. This will help other users find the same answer/resolution.  Thank you.

• ###### 4. Re: Visualization of colored values concerning True/False

Ah awesome! Thank you.

But there is still one thing. The grand total changes when i just filter for true or just for false. for exxample for building 5 it would present 61.54 percent instead of 100%. Even if i filter one of them i want to show them how much of these 100% is right and false when i filter them.

Is this also possible to change? That the grand total is always the same (fixed)?

• ###### 5. Re: Visualization of colored values concerning True/False

Nichole that is a separate question

Grand totals - total what is in the view -

you are using a table calculation to determine the Total Deliveries

I tried to follow your data but got lost in the detail - but replace the table calc with the LOD

Jim

Let me know if this helped

• ###### 6. Re: Visualization of colored values concerning True/False

Jim,

i am sorry. I am a really beginner in tableau and try to improve my skills.

How can i change the table calc with the LOD? I have no idea how to do it.

The thing is the importance is to see how much of the total deliverys were false. Therefore i want to show the percentage of the false one depending on the total view.

I know that the grand total shows always all information/values which are visualized thats the reason why it changes with different filter settings.

Thats the reason why i wanted to ask if there is another opportunity to show the totals, not with grand total, or if you can fix it that it will stay the total.

• ###### 7. Re: Visualization of colored values concerning True/False

Ok First welcome to tableau

if you haven't done so already look at the video training modules on the Tableau site - they are very good - Calculations is a good place to start

as noted earlier - you data is complex and I don't have the time here to go through it -

but below is a superstore example on how to use LOD calculations instead of table calculations to get the percent of each subcategory within catgeory

first determine the total sales in each category as

In words it says 'for each category sum the sales"  the way Fixed works is that it makes permutations of the dimension(s) that precede the colon then aggregates that by what follow the colon

Then the percent becomes

and they will return

Hope this helps

Jim

1 of 1 people found this helpful
• ###### 8. Re: Visualization of colored values concerning True/False

Hi Nicole - I have created something like the screenshot below for Checkout time. You can replicate it to create similar view for check ins. Also, you have have the Percentage variable that you can use in different ways to get the view that you need (can use it as different shapes).

I'm on 10.4 so I had to save it as a twb file format and then convert to 10.3 so that you can view it.

Hope it helps!

PS: Please mark it as helpful if it resolves your issue, so that others can benefit from it. Happy Learning!

• ###### 9. Re: Visualization of colored values concerning True/False

Hey Jim,

what does happen when i have further filters??

The total by category depends on the date of the sign in. I want to calculate the total amount of a week? Is this also possible?

Thanks for support!

Nicole