Tableau Collection 3: Formatting visualization shows percentage and tooltip alignment issues

I. Introduction

This article starts from the two small problems that the percentage cannot be displayed in the visualization graph and the tooltips cannot be aligned, and introduces some methods of using Tableau to set the format and tooltips.

Environment: Windows 11 64-bit, Tableau desktop 2021.2

2. Problem 1: The percentage cannot be displayed in the visualization

Description of the problem: Pull a picture, and use decimals to display related values ​​by default. If you want to display percentages, how to configure it?
image.png

2.1 Tableau setting format

There are generally two forms for setting the format of Tableau's visual graphic numbers:

  • Method 1: Right-click the field > Format to format the field data
  • Method 2: Set the format on the toolbar > click any one of font, alignment, shadow, border, line, etc. > select the corresponding field to set the format of the field data

Method 1 operates as shown in the figure below:
image.png
Method 2 operates as shown in the figure below:
image.png

The format setting windows called up by different fields are different, as shown in the animation below, which shows that different fields display different formats, and related fields will also be prompted in the first line of the window.
Set format 1.gif

When setting the format, you need to pay special attention to the range of setting such as axis and area, worksheet and row and column.
For example, when setting a field, 聚合(转化率)you cannot set the value format of the axis (as shown in Figure 1 below), but when setting the field 度量值, you can set the value format of the axis and the value format of the area (as shown in Figure 2).
Formatting - Measure cannot set axis.gif

Formatting - measure field can set axis and area.gif

2.2 Solutions

See the last animation in 2.1, right-click 度量值the field, and then set the number format of the area to percentage.

3. Problem 2: The tooltips cannot be prompted or aligned

Maybe many friends, especially beginners, don't know that Tableau's data prompts can be compared to DIY settings. By default, the data will give us the right and neat (as shown below).
image.png
But sometimes the picture I drew for the first time was not satisfactory, so I recreated it on the original worksheet, and after playing around, I found that the prompts of some fields had no value! (As shown in the picture below)
I didn’t know why at the beginning, maybe I created a new worksheet and did it again, and then found that the value came back again, everyone is happy ~~~
In fact, this problem can be solved by setting in the tooltip.
image.png

In the process of setting the tooltip, there are some small details that need to be paid attention to. As shown in the figure below, open the tooltip and add it 聚合(转化率)to 复购率:the back. You can see that there are two problems with the final prompt effect (the solution is attached below):

  • The font color is inconsistent with the previous one: open the tooltip, view the format of other fonts, and set the same format for the newly added field
  • The alignment is not uniform: open the prompt tool, place the cursor 复购率:behind 聚合(转化率), Tabpress the key , and add an indentation. Note that using spaces will also cause misalignment.

image.png
聚合(复购率)Note: Since or is repeatedly prompted in the tooltip 聚合(转化率), it can be deleted in the edit tooltip <度量名称>: <度量值>.

If you are careful, you may have noticed that the two indicators in the tooltip display decimals instead of percentages, and the values ​​in the area are all percentages.
In order to avoid confusion, we 度量值temporarily call the field 行度量值(placed in the 度量值field), as mentioned above 行度量值, there are some cards in the middle of the sidebar and the drawing area, and there is a 度量值functional area, which contains two measurement values 聚合(复购率)​​and sums 聚合(转化率).
Back to the question, the value in the area is 行度量值set through the field, but the number format of the sum of the two measurement value fields 聚合(复购率)is not set, so the number format of 聚合(转化率)the sum of the two measurement value fields in the tooltip is still a decimal. The solution is also very simple, right click on the two measurement values ​​> format > area, and set all to percentage. The figure below is a reference, there are many ways to modify, you can refer to 2.1.聚合(复购率)聚合(转化率)

Formatting - two metrics modify format.gif


Click this link to download related resources (Excel data and Tableau files) .

Guess you like

Origin blog.csdn.net/qq_45476428/article/details/128055797