class_docstr: Interface for creating and using matplotlib subplots based on seaborn parameters.
  
  Parameters
  ----------
  subplot_spec : dict
      Keyword args for :meth:`matplotlib.figure.Figure.subplots`.
  facet_spec : dict
      Parameters that control subplot faceting.
  pair_spec : dict
      Parameters that control subplot pairing.
  data : PlotData
      Data used to define figure setup.
class_docstr_tok: ["Interface","for","creating","and","using","matplotlib","subplots","based","on","seaborn","parameters",".","Parameters","--","--","--","--","--","subplot_spec",":","dict","Keyword","args","for",":","meth",":","`","matplotlib.figure.Figure.subplots","`",".","facet_spec",":","dict","Parameters","that","control","subplot","faceting",".","pair_spec",":","dict","Parameters","that","control","subplot","pairing",".","data",":","PlotData","Data","used","to","define","figure","setup","."]
docstr: Update subplot spec with default or specified axis sharing parameters.
docstr_tok: ["Update","subplot","spec","with","default","or","specified","axis","sharing","parameters","."]
code: def _determine_axis_sharing(self, pair_spec: PairSpec) -> None:
      """Update subplot spec with default or specified axis sharing parameters."""
      axis_to_dim = {"x": "col", "y": "row"}
      key: str
      val: str | bool
      for axis in "xy":
          key = f"share{axis}"
          # Always use user-specified value, if present
          if key not in self.subplot_spec:
              if axis in pair_spec.get("structure", {}):
                  # Paired axes are shared along one dimension by default
                  if self.wrap is None and pair_spec.get("cross", True):
                      val = axis_to_dim[axis]
                  else:
                      val = False
              else:
                  # This will pick up faceted plots, as well as single subplot
                  # figures, where the value doesn't really matter
                  val = True
              self.subplot_spec[key] = val
  
file_path: seaborn/seaborn/_core/subplots.py
imports: from __future__ import annotations
  from collections.abc import Generator
  import numpy
  import matplotlib
  import matplotlib.pyplot
  from matplotlib.axes import Axes
  from matplotlib.figure import Figure
  from typing import TYPE_CHECKING
label_desc: Use image node_id 5 for calling the Subplots obj's underlying member method code with example usage: obj._determine_axis_sharing(pair_spec) without return types