class_docstr: Base class for objects underlying *plot functions.
class_docstr_tok: ["Base","class","for","objects","underlying","*","plot","functions","."]
docstr: Add axis labels if not present, set visibility to match ticklabels.
docstr_tok: ["Add","axis","labels","if","not","present",",","set","visibility","to","match","ticklabels","."]
code: def _add_axis_labels(self, ax, default_x="", default_y=""):
      """Add axis labels if not present, set visibility to match ticklabels."""
      # TODO ax could default to None and use attached axes if present
      # but what to do about the case of facets? Currently using FacetGrid's
      # set_axis_labels method, which doesn't add labels to the interior even
      # when the axes are not shared. Maybe that makes sense?
      if not ax.get_xlabel():
          x_visible = any(t.get_visible() for t in ax.get_xticklabels())
          ax.set_xlabel(
              self.variables.get("x", default_x), visible=x_visible
          )
      if not ax.get_ylabel():
          y_visible = any(t.get_visible() for t in ax.get_yticklabels())
          ax.set_ylabel(
              self.variables.get("y", default_y), visible=y_visible
          )
  
imports: from __future__ import annotations
  import warnings
  import itertools
  from copy import copy
  from collections import UserString
  from collections.abc import Iterable, Sequence, Mapping
  from numbers import Number
  from datetime import datetime
  import numpy
  import pandas
  import matplotlib
  from seaborn._core.data import PlotData
  from seaborn.palettes import QUAL_PALETTES, color_palette
  from seaborn.utils import _check_argument, _version_predates, desaturate, locator_to_legend_entries, get_color_cycle, remove_na
label_desc: Use image node_id 14 for calling the VectorPlotter obj's underlying member method code with example usage: obj._add_axis_labels(ax, default_x, default_y) without return types