title: Matplotlib notebook cropped figure
body: <p>I am trying to make an interactive script in jupyter notebook that will draw different images in cycle and asks for user decision. I came to the point where I can redraw figure with 3 subplots, but have no idea how to configure the size of interactive figure to make all subplots visible. As you can see only part of the second subplot peeps out from the right.</p>
  
  <p>I will be grateful for any help.</p>
  
  <p><a href="https://i.stack.imgur.com/82OcY.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/82OcY.png" alt="cropped figure with 3 subplots"></a></p>
  
  <p>Here is my code:</p>
  
  <pre><code>import cv2
  import matplotlib.pyplot as plt
  import pandas as pd
  % matplotlib notebook
  
  fig, [ax1, ax2, ax3] = plt.subplots(1,3, figsize=(5, 5))
  ax1.set_xlabel("src")
  ax2.set_xlabel("rgb")
  ax3.set_xlabel("hsv")
  ax2.set_xlim([-1,257])
  ax3.set_xlim([-1,257])
  plt.legend(loc='upper right')
  
  color = ('r','g','b') # HSV colors
  labels = ('h', 's', 'v')  
  
  plt.subplots_adjust(right = 2.3) 
  
  for i in range(0,3):
    im = cv2.imread("image.png")
    im_rgb = cv2.cvtColor(im, cv2.COLOR_BGR2RGB)
    im_hsv = cv2.cvtColor(im, cv2.COLOR_BGR2HSV)
    ax1.imshow(im_rgb, cmap='gray')
    for i,col in enumerate(color):
      histr = cv2.calcHist([im_rgb],[i],None,[256],[0,256])
      ax2.plot(histr, color = col, label=col)
    for i,col in enumerate(color):
      histr = cv2.calcHist([im_hsv],[i],None,[256],[0,256])
      ax3.plot(histr, color = col, label=labels[i])
    fig.canvas.draw()  
    answer = input("Next? " )
  </code></pre>