Algoteka
Log in to submit your own samples!

Plot a Pie Chart

Problem by oml1111
# Tech tags Title Creator Created date
1 0
Matplotlib
2022-12-17 02:41
View all samples for this language (1 verified and 0 unverified)

Solution | Python | Matplotlib |

By oml1111 |
0 likes

Renders the following pie chart:
Matplotlib Pie Chart

Code

import matplotlib.pyplot as plt

plt.pie([3, 7, 5], labels=["a", "b", "xy"])
plt.show()

Further reading

Basic pie chart - matplotlib.org

References

functions
matplotlib.pyplot.pie matplotlib.org
matplotlib.pyplot.show matplotlib.org

Problem Description

Plot a categorical bar graph containing at least 3 labeled slices. Include a picture of the graph in the specification.

View sample discussion (0 comments)
View problem discussion (0 comments)