You can use subplot()
:
pl.figure(figsize=(12, 6))
pl.subplot(1, 2, 1)
for axeid in (3, 4, 7, 8):
pl.subplot(2, 4, axeid)
the output is:
Frage
I want to make a plot in matplotlib with subplots arranged like so:
Where each of the colored squares represents a different subplot. How can I get matplotlib to make two subplots, one of which has several sub-subplots?
Lösung
You can use subplot()
:
pl.figure(figsize=(12, 6))
pl.subplot(1, 2, 1)
for axeid in (3, 4, 7, 8):
pl.subplot(2, 4, axeid)
the output is: