Python draws six kinds of visual charts in detail, and 3D charts are the coolest! What do you think?
There are quite a few kinds of visual charts, but the common ones are the following, others are a bit more complex and are mostly based on the following combinations and transformations. For beginners, it's easy to be intimidated by the many types of charts on this official website, and with so much variety, there's a good chance that several charting methods will get confused.
So here, I've summarized six common basic chart types that you can learn by comparison and build a solid foundation.
1. folded line graph
Plotting a line graph, if you don't have a lot of data, the graph will be zigzag, but once your data set is large, like our example below, there are 100 points, so what we see with the naked eye will be a smooth curve.
Here I plotted three lines and just executed plt.plot three times.
2. scatterplot
In fact, scatter diagrams and line graphs are the same principle, connecting the points in a scatter diagram with a line is a line graph. So to plot a scatter plot, just set the line type.
Note: Here I also plot three lines, unlike above, I only use one plt.plot for this.
3. bar chart
The histogram, which is not new to everyone. Here Ming increases the difficulty by drawing two frequency histograms in one graph. This should be encountered on the actual scenario as well, because that really makes it easy to compare, right?
4. histogram
Again, instead of the simple bar chart, I'll draw three of the more difficult ones here.
4.1 Side-by-side bar chart
4.2 Superimposed bar chart
5. pie chart
5.1 General pie chart
5.2 Nested pie charts
5.3 Polar axis pie chart
For coolness, the polar axis pie chart is one of the best, and it's definitely something to learn here.
6. three-dimensional figure
6.1 Plotting a 3D scatter plot
6.2 Drawing of the 3D plan
What do you think of that dazzler?
favorite
share (joys, benefits, privileges etc) with others
or