October 2018
Beginner to intermediate
676 pages
18h 30m
English
The following code block plots three grids of different numbers of cells and sizes in one figure:
plt.style.use('ggplot')fig = plt.figure(figsize=(12,6), constrained_layout=True)
gs0 = GridSpec(1, 3, figure=fig)
gs00 = GridSpecFromSubplotSpec(2, 2, subplot_spec=gs0[0])gs01 = GridSpecFromSubplotSpec(3, 2, subplot_spec=gs0[1])gs02 = GridSpecFromSubplotSpec(3, 3, subplot_spec=gs0[2])
for a in range(2): for b in range(2): fig.add_subplot(gs00[a, ...
Read now
Unlock full access