code: def ptp(a, axis=None, out=None, keepdims=False):
      """Returns the range of values (maximum - minimum) along an axis.
  
      .. note::
  
         The name of the function comes from the acronym for 'peak to peak'.
  
         When at least one element is NaN, the corresponding ptp value will be
         NaN.
  
      Args:
          a (cupy.ndarray): Array over which to take the range.
          axis (int): Axis along which to take the minimum. The flattened
              array is used by default.
          out (cupy.ndarray): Output array.
          keepdims (bool): If ``True``, the axis is retained as an axis of
              size one.
  
      Returns:
          cupy.ndarray: The minimum of ``a``, along the axis if specified.
  
      .. note::
         When cuTENSOR accelerator is used, the output value might be collapsed
         for reduction axes that have one or more NaN elements.
  
      .. seealso:: :func:`numpy.amin`
  
      """
      return a.ptp(axis=axis, out=out, keepdims=keepdims)
  
file_path: cupy/cupy/_statistics/order.py
imports: import warnings
  import cupy
  from cupy import _core
  from cupy._core import _routines_statistics
  from cupy._core import _fusion_thread_local
  from cupy._logic import content
label_desc: Use image node_id 5 for calling a global function with example usage: ptp(a, axis, out, keepdims) and returns: a