How to separate two charts⁉️ [SOLVED] | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 3

How to separate two charts⁉️ [SOLVED]

I'm trying to plot two charts in one code, a 'pie' & a 'bar' charts but they overlap‼️ How to separate them ⁉️ https://code.sololearn.com/cA16a3A4A16a/?ref=app

17th Mar 2021, 12:21 PM
Janusz Bujak 🇵🇱 🇺🇦
Janusz Bujak 🇵🇱 🇺🇦 - avatar
2 Answers
+ 5
https://code.sololearn.com/ckYim3l5r49G/?ref=app
17th Mar 2021, 12:39 PM
visph
visph - avatar
+ 5
You can use subplots fig, axes = plt.subplots(nrows=2) or fig, axes = plt.subplots(ncols=2) and do s.plot(kind='pie', ax=axes[0]) s.plot(kind='bar', ax=axes[1]) https://matplotlib.org/stable/api/_as_gen/matplotlib.pyplot.subplots.html
17th Mar 2021, 12:48 PM
你知道規則,我也是
你知道規則,我也是 - avatar