docstr: Return a sequential colormap given a color seed.
docstr_tok: ["Return","a","sequential","colormap","given","a","color","seed","."]
code: def _cmap_from_color(self, color):
      """Return a sequential colormap given a color seed."""
      # Like so much else here, this is broadly useful, but keeping it
      # in this class to signify that I haven't thought overly hard about it...
      r, g, b, _ = to_rgba(color)
      h, s, _ = husl.rgb_to_husl(r, g, b)
      xx = np.linspace(-1, 1, int(1.15 * 256))[:256]
      ramp = np.zeros((256, 3))
      ramp[:, 0] = h
      ramp[:, 1] = s * np.cos(xx)
      ramp[:, 2] = np.linspace(35, 80, 256)
      colors = np.clip([husl.husl_to_rgb(*hsl) for hsl in ramp], 0, 1)
      return mpl.colors.ListedColormap(colors[::-1])
  
imports: from numbers import Number
  from functools import partial
  import math
  import textwrap
  import warnings
  import numpy
  import pandas
  import matplotlib
  import matplotlib.pyplot
  import matplotlib.transforms
  from matplotlib.cbook import normalize_kwargs
  from matplotlib.colors import to_rgba
  from matplotlib.collections import LineCollection
  from ._base import VectorPlotter
  from ._statistics import ECDF, Histogram, KDE
  from ._stats.counting import Hist
  from .axisgrid import FacetGrid, _facet_docs
  from .utils import remove_na, _get_transform_functions, _kde_support, _check_argument, _assign_default_kwargs, _default_color
  from .palettes import color_palette
  from .external import husl
  from .external.kde import gaussian_kde
  from ._docstrings import DocstringComponents, _core_docs
label_desc: Use image node_id 8 for calling the _DistributionPlotter obj's underlying member method code with example usage: obj._cmap_from_color(color) and returns: mpl