code: def position_stack(vjust=None, mode=None):
      """
      Adjust position by stacking overlapping objects on top of each other.
      Preferred for density-like geometries.
  
      Parameters
      ----------
      vjust : float
          Vertical adjustment for geoms that have a position (like points or lines),
          not a dimension (like bars or areas).
          Set to 0 to align with the bottom, 0.5 for the middle, and 1 for the top.
      mode : {'groups', 'all'}, default='groups'
          If 'groups', objects inside one group are positioned as in `position='identity'`,
          but each group is shifted to sum of heights of previous groups
          (where height of a group is a maximum of it's y values).
          If 'all', each object will be shifted.
  
      Returns
      -------
      `FeatureSpec`
          Geom object position specification.
  
      Notes
      -----
      Adjust position by stacking overlapping objects on top of each other.
  
      Examples
      --------
      .. jupyter-execute::
          :linenos:
          :emphasize-lines: 9
  
          from lets_plot import *
          LetsPlot.setup_html()
          data = {
              'x': [1, 1, 1, 2, 2, 2],
              'y': [1, 2, 3, 1, 2, 3],
              'g': ["a", "b", "b", "a", "a", "b"],
          }
          ggplot(data, aes('x', 'y', color='g')) + \\
              geom_point(position=position_stack(), size=10)
  
      """
      return _pos("stack", vjust=vjust, mode=mode)
  
file_path: lets-plot/python-package/lets_plot/plot/pos.py
imports: from .core import FeatureSpec
label_desc: Use image node_id 6 for calling a global function with example usage: position_stack(vjust, mode) and returns: _pos