# scipy 1.18.1 (BSD-3-Clause), harvested by tools/harvest_corpus.py
=== input

    Compute the Sokal-Sneath dissimilarity between two boolean 1-D arrays.

    The Sokal-Sneath dissimilarity between `u` and `v`,

    .. math::

       \frac{R}
            {c_{TT} + R}

    where :math:`c_{ij}` is the number of occurrences of
    :math:`\mathtt{u[k]} = i` and :math:`\mathtt{v[k]} = j` for
    :math:`k < n` and :math:`R = 2(c_{TF} + c_{FT})`.

    Parameters
    ----------
    u : (N,) array_like, bool
        Input array.
    v : (N,) array_like, bool
        Input array.
    w : (N,) array_like, optional
        The weights for each value in `u` and `v`. Default is None,
        which gives each value a weight of 1.0

    Returns
    -------
    sokalsneath : double
        The Sokal-Sneath dissimilarity between vectors `u` and `v`.

    Examples
    --------
    >>> from scipy.spatial import distance
    >>> distance.sokalsneath([1, 0, 0], [0, 1, 0])
    1.0
    >>> distance.sokalsneath([1, 0, 0], [1, 1, 0])
    0.66666666666666663
    >>> distance.sokalsneath([1, 0, 0], [2, 1, 0])
    0.0
    >>> distance.sokalsneath([1, 0, 0], [3, 1, 0])
    -2.0

    
=== parse numpydoc
short_description: 'Compute the Sokal-Sneath dissimilarity between two boolean 1-D arrays.'
long_description: |
  The Sokal-Sneath dissimilarity between `u` and `v`,
  
  .. math::
  
     \frac{R}
          {c_{TT} + R}
  
  where :math:`c_{ij}` is the number of occurrences of
  :math:`\mathtt{u[k]} = i` and :math:`\mathtt{v[k]} = j` for
  :math:`k < n` and :math:`R = 2(c_{TF} + c_{FT})`.
blank_after_short_description: True
blank_after_long_description: True
style: numpydoc
- DocstringParam
  description: 'Input array.'
  kind: param
  key: 'param'
  arg_name: 'u'
  type_name: '(N,) array_like, bool'
  is_optional: False
- DocstringParam
  description: 'Input array.'
  kind: param
  key: 'param'
  arg_name: 'v'
  type_name: '(N,) array_like, bool'
  is_optional: False
- DocstringParam
  description: |
    The weights for each value in `u` and `v`. Default is None,
    which gives each value a weight of 1.0
  kind: param
  key: 'param'
  arg_name: 'w'
  type_name: '(N,) array_like'
  is_optional: True
  default: 'None'
  raw_type_name: '(N,) array_like, optional'
- DocstringReturns
  description: 'The Sokal-Sneath dissimilarity between vectors `u` and `v`.'
  kind: returns
  key: 'returns'
  type_name: 'double'
  is_generator: False
  return_name: 'sokalsneath'
- DocstringExample
  kind: examples
  key: 'examples'
  snippet: '>>> from scipy.spatial import distance'
- DocstringExample
  kind: examples
  key: 'examples'
  snippet: |
    >>> distance.sokalsneath([1, 0, 0], [0, 1, 0])
    1.0
- DocstringExample
  kind: examples
  key: 'examples'
  snippet: |
    >>> distance.sokalsneath([1, 0, 0], [1, 1, 0])
    0.66666666666666663
- DocstringExample
  kind: examples
  key: 'examples'
  snippet: |
    >>> distance.sokalsneath([1, 0, 0], [2, 1, 0])
    0.0
- DocstringExample
  kind: examples
  key: 'examples'
  snippet: |
    >>> distance.sokalsneath([1, 0, 0], [3, 1, 0])
    -2.0
=== detect
numpydoc
=== compose numpydoc
Compute the Sokal-Sneath dissimilarity between two boolean 1-D arrays.

The Sokal-Sneath dissimilarity between `u` and `v`,

.. math::

   \frac{R}
        {c_{TT} + R}

where :math:`c_{ij}` is the number of occurrences of
:math:`\mathtt{u[k]} = i` and :math:`\mathtt{v[k]} = j` for
:math:`k < n` and :math:`R = 2(c_{TF} + c_{FT})`.

Parameters
----------
u : (N,) array_like, bool
    Input array.
v : (N,) array_like, bool
    Input array.
w : (N,) array_like, optional
    The weights for each value in `u` and `v`. Default is None,
    which gives each value a weight of 1.0

Returns
-------
sokalsneath : double
    The Sokal-Sneath dissimilarity between vectors `u` and `v`.

Examples
--------
>>> from scipy.spatial import distance
>>> distance.sokalsneath([1, 0, 0], [0, 1, 0])
1.0
>>> distance.sokalsneath([1, 0, 0], [1, 1, 0])
0.66666666666666663
>>> distance.sokalsneath([1, 0, 0], [2, 1, 0])
0.0
>>> distance.sokalsneath([1, 0, 0], [3, 1, 0])
-2.0
