Python Forum
How to create matplotlib subplots from figures
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to create matplotlib subplots from figures
#1
I want to create subplots from a number of figures I created in different parts of the code which may include linear regression plots, boxplots, etc. I tried my best but could not find a solution.
Reply
#2
Hi @vitaly
To do that, you have to use joypy package to create subplots from various figures.

JoyPy is a one-function Python package based on matplotlib + pandas with a single purpose: drawing joyplots (a.k.a. ridgeline plots).
Reply
#3
Hi GodMaster. Thanks for your response.
I don't think I need ridgeline plots. What I need is to create a bunch of figures and combine them as subplots of a single graph.
It is like
fig1 = plt.figure(constrained_layout=True)
…..
plt.plot(X, Y)

fig2 = plt.figure(constrained_layout=True)
…..
plt.boxplot(…..
……..
and then combine these figures in one plot.

If you still think it can be done with JoyPy, please give me an example.
Reply
#4
There are lots of examples how to put several plots on a figure. See matplotlib gallery.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
Question I’m trying to create a Power BI Matplotlib quadrant chart and I’m a little stumped. Nidwolff 1 328 Mar-04-2024, 06:07 AM
Last Post: Danishhafeez
  matplotlib.pyplot functions create new figures instead of applying to the current one karkas 2 2,049 Jul-09-2020, 08:32 AM
Last Post: karkas
  Loss and Accuracy Figures. Hani 3 2,983 May-20-2020, 06:55 PM
Last Post: jefsummers
  Superimpose figures Scientifix 2 4,631 Aug-16-2019, 04:06 PM
Last Post: Nitram
  Dynamically placing axes in subplots via dataframe plot naftis 1 2,921 Jul-29-2019, 12:10 AM
Last Post: scidam
  For loop that prints four subplots dervast 4 2,257 Jul-02-2019, 10:54 AM
Last Post: dervast
  how can I create a recursive graphic with matplotlib royer14 3 3,695 Nov-22-2018, 05:00 PM
Last Post: Gribouillis
  how can I create graphics using matplotlib royer14 8 4,145 Nov-21-2018, 07:02 AM
Last Post: Gribouillis
  How to superscript figures? Felipe 0 3,027 Feb-06-2017, 05:56 PM
Last Post: Felipe

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020