class_docstr: Format function default values as needed for inspect.formatargspec.
  The interesting part is a hard-coded list of functions used
  as defaults in pyplot methods.
class_docstr_tok: ["Format","function","default","values","as","needed","for","inspect.formatargspec",".","The","interesting","part","is","a","hard-coded","list","of","functions","used","as","defaults","in","pyplot","methods","."]
code: def __init__(self, value):
      if value is mlab.detrend_none:
          self._repr = "mlab.detrend_none"
      elif value is mlab.window_hanning:
          self._repr = "mlab.window_hanning"
      elif value is np.mean:
          self._repr = "np.mean"
      elif value is _api.deprecation._deprecated_parameter:
          self._repr = "_api.deprecation._deprecated_parameter"
      elif isinstance(value, Enum):
          # Enum str is Class.Name whereas their repr is <Class.Name: value>.
          self._repr = str(value)
      else:
          self._repr = repr(value)
  
imports: import ast
  from enum import Enum
  import functools
  import inspect
  from inspect import Parameter
  from pathlib import Path
  import sys
  import subprocess
  import numpy
  from matplotlib import _api, mlab
  from matplotlib.axes import Axes
  from matplotlib.backend_bases import MouseButton
  from matplotlib.figure import Figure
label_desc: Use image node_id 1 to create a new value_formatter object  with example: obj = value_formatter(value)