Wiki源代码5.8.2.3 Pie chart

由用户 maym 在 2025/03/10 08:26 保存的版本 14.9

显示最后作者
1 ==== **[Usage Scenario]** ====
2
3 A pie chart is a commonly used type of data visualization chart that presents data as a circular shape resembling a pie chart, displaying the proportions of different data classifications in a fan-shaped manner. It is suitable for the following scenarios:
4
5 * (((
6 **Proportional display:** A pie chart is suitable for displaying the proportion or proportion relationship of different categories in the population. For example, market share, the proportion of various expenses to total expenses, etc.
7 )))
8 * (((
9 **Category Display:** A pie chart can classify and display data according to different categories, visually showing comparisons between different categories. For example, the sales proportion of different products, the sales proportion of different regions, etc.
10 )))
11 * (((
12 **Trend analysis:** By observing the size changes of each sector in the pie chart, the trend and changes of the data can be analyzed. For example, seasonal changes in sales revenue, changes in the proportion of users in different age groups, etc.
13 )))
14 * (((
15 **Highlights**: Specific data or categories can be emphasized by highlighting a sector or several important sectors in the pie chart. For example, highlighting the market share of a certain product, highlighting the sales proportion of a certain region, etc.
16 )))
17
18 ==== **[Basic Requirements ]** ====
19
20 The basic requirements for a pie chart are as follows:
21
22 (% style="width:584px" %)
23 |(% style="width:280px" %)Category Field|(% style="width:300px" %)Mumeric Field
24 |(% style="width:280px" %)Only one field can be configured|(% style="width:300px" %)Only one field can be configured
25
26 **Step-1 Select components and configure data sources**
27
28 Create a report, select the pie chart in the upper left corner, and then choose the data source, as shown in the figure:
29
30 [[image:1729843622506-386.png||height="546" width="767"]]
31
32
33 **Step-2 Select chart display fields**
34
35 Drag and drop the fields from the data source on the right onto the classification and numerical fields.
36
37 * (((
38 Data source for pie chart:
39
40 With the classification field and numerical field, it is possible to draw the correct pie chart based on the actual situation of the data. In the following figure:将销售物品类型拖入分类字段中,将销售数量拖入数值字段中,则可以得出:【按照销售物品类型分类后的销售数量的统计饼状图】
41
42
43 * (((
44 **Classification field:** This field represents the category or classification of the data, and each data point should have a corresponding category. The category field can be product name, region name, department name, etc., used to indicate the specific category to which the data belongs.
45 )))
46 * (((
47 **Numerical field:** This field represents the specific numerical value/quantity for each category. Numerical fields can be sales revenue, sales quantity, market share, etc., used to represent the proportion or percentage of each category in the overall population.
48
49 (((
50 ====== If a non numeric field (such as string, date, location type) is dragged into a numeric field (dashed box), the string, date, location will be converted to the number of times the field appears based on the default aggregation method (count). ======
51 )))
52
53 [[image:1729749814387-113.png||height="669" width="1300"]]
54 )))
55 )))
56
57 **Step-3 Style settings**
58
59 Divided into three categories: Basic Settings, Labels, and Legends, as shown in the following figure:
60
61 [[image:1729750188515-947.png||height="766" width="1425"]]
62
63
64 (((
65
66 )))
67
68 (((
69
70
71
72 )))
73
74 ==== **[Style Configuration Description]** ====
75
76 |(% colspan="1" rowspan="1" style="width:107px" %)Classification|(% colspan="1" rowspan="1" style="width:150px" %)Configuration Items|(% colspan="1" rowspan="1" style="width:1304px" %)(((
77 Purpose
78 )))
79 |(% colspan="1" rowspan="6" style="width:107px" %)(((
80 Basic Style
81
82
83 )))|(% colspan="1" rowspan="1" style="width:150px" %)Show heading|(% colspan="1" rowspan="1" style="width:1304px" %)(((
84 Control whether the chart title in the upper left corner of the canvas is displayed. When closed, the chart title will not be displayed in the report, The words "柱状图1" are shown in the following figure
85
86 [[image:1729754356435-491.png]]
87 )))
88 |(% colspan="1" rowspan="1" style="width:150px" %)Chart title|(% colspan="1" rowspan="1" style="width:1304px" %)You can name the chart by yourself
89 |(% colspan="1" rowspan="1" style="width:150px" %)Help text|(% colspan="1" rowspan="1" style="width:1304px" %)Control whether the help copy is displayed in the chart. If enabled, client users can see a "?" icon after the chart title and the corresponding help copy when moving the mouse over the icon
90 [[image:1729754478509-444.png]]
91 |(% colspan="1" rowspan="1" style="width:150px" %)Help text content|(% colspan="1" rowspan="1" style="width:1304px" %)Enter a description of the chart here to help client users understand the chart data
92 |(% colspan="1" rowspan="1" style="width:150px" %)Pie chart type|(% colspan="1" rowspan="1" style="width:1304px" %)(((
93 By default, "General" is selected. The second option is a circular chart, which has the following effect:
94
95 [[image:1729754564047-207.png||height="451" width="1137"]]
96
97
98 )))
99 |(% colspan="1" rowspan="1" style="width:150px" %)Color scheme|(% colspan="1" rowspan="1" style="width:1304px" %)Customize the color scheme of the Y-axis pillar
100 |(% colspan="1" rowspan="5" style="width:107px" %)(((
101 Label
102
103
104 )))|(% colspan="1" rowspan="1" style="width:150px" %)(((
105 Display Label
106 )))|(% colspan="1" rowspan="1" style="width:1304px" %)(((
107 (((
108 Control whether to display the labels of the pie chart, as shown in the following figure:
109
110 [[image:1729754768467-631.png||height="523" width="1081"]]
111 )))
112
113 (((
114
115 )))
116 )))
117 |(% colspan="1" rowspan="1" style="width:150px" %)Color font size|(% colspan="1" rowspan="1" style="width:1304px" %)Support user-defined color and font size for label
118 |(% colspan="1" rowspan="1" style="width:150px" %)(((
119 Label position
120
121
122 )))|(% colspan="1" rowspan="1" style="width:1304px" %)Provide 3 modes: internal, external, spider diagram
123 |(% colspan="1" rowspan="1" style="width:150px" %)(((
124 Label content
125
126
127 )))|(% colspan="1" rowspan="1" style="width:1304px" %)(((
128 It is a combination of titles, percentages, and values arranged in various ways. The default combination is [title, percentage], but users can also change it to other content, such as the "title, value (percentage)" combination, as shown in the following figure:
129
130 [[image:1729756074259-175.png]]
131
132
133 )))
134 |(% colspan="1" rowspan="1" style="width:150px" %)% decimals|(% colspan="1" rowspan="1" style="width:1304px" %)(((
135 Set the decimal places for percentages in the above labels, for example, to display 3 decimal places, as shown in the following figure:
136
137 [[image:1729756197988-684.png]]
138
139
140
141 )))
142 |(% colspan="1" rowspan="3" style="width:107px" %)(((
143 Legend
144 )))|(% colspan="1" rowspan="1" style="width:150px" %)(((
145 Show legend
146 )))|(% colspan="1" rowspan="1" style="width:1304px" %)(((
147 By default, it is turned on, and when turned off, the legend will not be displayed
148
149 [[image:1729756246566-930.png]]
150 )))
151 |(% colspan="1" rowspan="1" style="width:150px" %)Legend position|(% colspan="1" rowspan="1" style="width:1304px" %)(((
152 The legend defaults to the top left corner of the chart and supports displaying the legend in other positions of the chart, such as the top center, bottom left corner, top right corner, bottom center, or bottom right corner
153 )))
154 |(% colspan="1" rowspan="1" style="width:150px" %)Color and font size|(% colspan="1" rowspan="1" style="width:1304px" %)Adjust the text color and font size of the legend