The latest Python big data Excel advanced

Excel chart types

To reveal data patterns

To be persuasive and facilitate communication

Professional charts can demonstrate professionalism

Learn what chart types are available

bar chart

line chart

pie chart

area chart

radar chart

Excel chart usage

How charts are created

The data source of the chart is generally a statistical summary table or a detailed table with a relatively small amount of data.

Depending on the data source, there are two methods for creating basic charts:

1. Create a chart using a fixed data area, that is, create a chart based on a fixed data area in the worksheet

2. Use fixed constants to create charts, that is, the data used to create charts are fixed constant data.

Create charts using fixed data ranges

1. Utilize all data in the continuous area

To use all the data in a continuous range of the worksheet, just click any cell in the data range and insert a chart through the Insert Chart command.

image-20220809161632924

Select some data

First select the data to be used to create the table, and then insert the selected type of chart through the Insert Chart command.

image-20220809161715921

Create charts using fixed constants

•Select any cell, click the Insert tab, and select the appropriate type of chart

image-20220809161807132

•A blank chart will be inserted at this time. We select the chart, switch the chart design tab, and click to select the data icon.

image-20220809161934520

•Select the Add button to add a data source

image-20220809164935857

Enter coordinate names and data.

image-20220809164952073

•Select the data information to be displayed on the chart and click Edit to edit the week labels

image-20220809165039877 image-20220809165048199

Click OK to generate the chart

image-20220809165328599

Chart introduction

After the chart is created. If the user finds that the created chart does not meet the actual needs, he can also edit it appropriately.

image-20220809165352151

Change chart type

1. After the chart is created, it is found that the chart type cannot meet the needs of visual analysis. You can change the chart type.

Right-click on the chart to bring up the menu and select Change Chart Type.

image-20220809165416617

•Select the chart type you want to modify, click OK, and the chart type change is completed.

image-20220809165455155 image-20220809165504215

1. In some cases, it is necessary to set a certain data series to another chart type

•Similarly right-click to bring up the drop-down menu and click to change the chart type.

image-20220809165534842

1. Add data series

Reselect data through the Select Data dialog box in the chart design

•Select the chart of the data series you want to add

image-20220809165551438

Edit data series

•Right-click or switch to the chart design tab and click to select the data icon

image-20220809165700113

Click the upward arrow to reselect the data area.

image-20220809165721540

•At this point, the newly selected data series is already in the list. Click OK to complete the series addition.

image-20220809165830150

1. Of course, there is an easier way to add data columns through the ctrl+c ctrl+v shortcut keys

•Select the data series to be added with the mouse and press ctrl+c

image-20220809165849419

Select the chart and press ctrl+v

image-20220809165918695

Not all charts require a legend. Charts generally have a legend by default, and you can delete/add/modify its position, etc.

•Can be operated through the menu or selected by dragging the mouse

image-20220809165942584

In addition to pie charts and donut charts, other standard charts generally have at least two axes.

Newly created charts do not have axis titles by default. Adding axis titles can make the meaning of the axis clearer.

•You can set the axis title through the Chart Design tab—>Add Chart Element—>Axis Title option

image-20220809170001310

Add data labels

1. Data labels refer to the data that displays information about the icons in the chart.

•Select the Chart Design tab and select Add Chart Element Label—>Data Label—>Best Match to automatically adapt the data label.

image-20220809170036835

1. The added data labels are all numerical values ​​by default. In some cases, they need to be displayed in other forms such as percentages and can be modified.

Right-click the chart to bring up the menu and select Format Data Labels.

image-20220809170052925

•Modify the label in the empty color box and change the "value" to "percent", then the modification is successful.

image-20220809170120523

Format chart

Ensure chart integrity

A complete chart must contain the following basic elements: chart title, data series, legend, axis, and data units

image-20220809170236659

Format chart area/drawing area

Chart area format settings mainly include font, background fill, border, size, attributes, etc.

image-20220809170514295

Format chart titles, axis titles, legends

The settings for chart titles, axis titles and legends are relatively simple, generally including settings for fonts, borders, alignment, position, etc.

image-20220809170545471

Format axes

Coordinate axes include classification axes and numerical axes. Setting items include fonts, lines, fills, alignments, axis options, etc.

image-20220809170606351

Format data sequence

Contents that need to be formatted in the data sequence may include: ① Setting the border/fill color ② Class spacing and overlap ratio ③ Coordinate axis position

image-20220809170642373

Data labels mainly include label content, label position, font, alignment, etc.

image-20220809170710430

Excel pivot table

Pivot table requirements for raw data

All data in one table

The raw data of the pivot table needs to be placed in one worksheet rather than in multiple worksheets.

If the data is placed in different worksheets by month/category/specification, the different worksheets will be merged into the same table first and then the pivot table will be created.

image-20220809171030068

The data must be a one-dimensional table, not a two-dimensional table

The original data of the pivot table should be a one-dimensional table, that is, the first row of the table is the field name, and the following is the data corresponding to the field.

Pivot tables cannot be successfully created with two-dimensional tables.

image-20220809171121980

Do not have null values ​​in the table

There should be no empty rows/columns in the original data. If the data is missing or has a "0" value, it is recommended to enter "0" instead of a blank cell.

As shown in the figure below, the first row of the table is blank, which will cause errors in the pivot table fields. There are blank rows in the middle of the table, which will cause null values ​​in the pivot table.

image-20220809171152298

Do not have merged cells in the table

Do not have merged cells in the original table of the pivot table, otherwise it will easily lead to errors in pivot analysis.

How to fill merged cells: Cancel merged cells -> Select the empty cells to be filled -> Enter the formula -> Press Ctrl+Enter to repeat the operation.

image-20220809171224443

The data format must be correct

In the original data table, the data format must be set correctly, especially the date data, which cannot be set to text data. Otherwise, the pivot table cannot be used to summarize the date data, and the slicer cannot be further used to analyze the data.

image-20220809171245092

Create a PivotTable

•Use recommended pivot tables

In the original data table, click the [Recommended Pivot Table] button in the [Table] group under the [Insert] tab, and a series of recommended pivot tables will appear.

. As shown in the figure below, select different pivot tables and you can see the details of the pivot tables on the right.

image-20220809171319175

•Create custom pivot tables

The way to customize a pivot table is to click the [Pivot Table] button under the [Insert] tab, and the dialog box as shown below will appear.

image-20220809171351087

Pivot table field layout

Overview

After the pivot table is successfully created, you need to set the fields appropriately, flexibly change the data presentation form, and conduct data analysis from different perspectives.

When necessary, charts can also be used to visually display and analyze data.

image-20220809171421117

Understanding fields

After creating a pivot table, the Excel panel is divided into three areas. The left is the pivot table display area, the upper right is the field list area, and the lower right is the field setting area.

Field layout steps: Check the required fields => Set fields => (Filtering, calculation method) => Check whether the pivot table meets the requirements

image-20220809171455622

Understanding fields

The field list displays all the fields in the original data. Here you can check the required fields according to your needs.

If you need to analyze the sales of different products by different salesmen, you need to check the three fields of "Salesperson", "Product Name" and "Sales Volume".

If you need to analyze the sales of different salesmen and different product categories, you need to check the three fields of "Salesperson", "Category" and "Amount (yuan)".

image-20220809171518633

Understanding fields

After the fields are checked, you need to set the fields.

There are two main points in field setting: that is, what data are displayed in the columns and rows of the pivot table, and what is the statistical method of the data.

image-20220809171545505

Field settings

•Move fields

First, fields can be added directly to the area below by dragging them from the field list. As shown in the two pictures below, the left picture selects a field from the field list, drags it down to the area shown in the right picture, and then releases the mouse to complete the field addition.

image-20220809171612471

Field settings

Secondly, the fields added to the bottom can be adjusted by dragging.

As shown in the picture below on the left, "Date" is in the [Row] area. Select "Date" and drag it to the [Column] area.

image-20220809171634671

Field settings

•Set the value of a field

A pivot table is a table that can quickly summarize large amounts of data. In the field setting area of ​​the pivot table, the fields in the [Value] area will be counted.

By default the statistics method is summation. If the "amount (yuan)" field is placed in this area, the sales data will be summed.

image-20220809171739678

final effect

Analyze the sales of different products by different salesmen

Analyze the sales of different salespersons and different product categories

image-20220809171754181

Add PivotChart

How to add a perspective chart: Select the cells in the pivot table area, and select [Pivot Chart] in the [Tools] group under the [Pivot Table Analysis] tab.

image-20220809171823822

PivotChart content filtering

Pivot charts are dynamic charts, and the chart content can be adjusted through the drop-down menus near the axes and legend.

image-20220809172616265

Pivot charts are dynamic charts, and the chart content can be adjusted through the drop-down menus near the axes and legend.

image-20220809172645502

Turn a PivotChart into a normal chart

The pivot chart will change as the data in the pivot table changes. If you want to turn the pivot chart into an ordinary static chart, you only need to copy the pivot table, delete the original data, and the pivot chart can become a chart.

image-20220809172708969

Guess you like

Origin blog.csdn.net/xianyu120/article/details/133269152