title: How to unset `sharex` or `sharey` from two axes in Matplotlib
body: <p>I have a series of subplots, and I want them to share x and y axis in all but 2 subplots (on a per-row basis).</p>
  
  <p>I know that it is possible to create all subplots separately and then <a href="https://stackoverflow.com/questions/42973223/how-share-x-axis-of-two-subplots-after-they-are-created">add the <code>sharex</code>/<code>sharey</code> functionality afterward</a>.</p>
  
  <p>However, this is a lot of code, given that I have to do this for most subplots. </p>
  
  <p>A more efficient way would be to create all subplots with the desired <code>sharex</code>/<code>sharey</code> properties, e.g.:</p>
  
  <pre><code>import matplotlib.pyplot as plt
  
  fix, axs = plt.subplots(2, 10, sharex='row', sharey='row', squeeze=False)
  </code></pre>
  
  <p>and then set <em>unset</em> the <code>sharex</code>/<code>sharey</code> functionality, which could <strong>hypothetically</strong> work like:</p>
  
  <pre><code>axs[0, 9].sharex = False
  axs[1, 9].sharey = False
  </code></pre>
  
  <p>The above does not work, but is there any way to obtain this?</p>