parameters: (n, dtype=None, *, like=None)
return_statement: return eye(n, dtype=dtype, like=like)
docstring: Return the identity array.
  
      The identity array is a square array with ones on
      the main diagonal.
  
      Parameters
      ----------
      n : int
          Number of rows (and columns) in `n` x `n` output.
      dtype : data-type, optional
          Data-type of the output.  Defaults to ``float``.
      ${ARRAY_FUNCTION_LIKE}
  
          .. versionadded:: 1.20.0
  
      Returns
      -------
      out : ndarray
          `n` x `n` array with its main diagonal set to one,
          and all other elements 0.
  
      Examples
      --------
      >>> np.identity(3)
      array([[1.,  0.,  0.],
             [0.,  1.,  0.],
             [0.,  0.,  1.]])
docstring_summary: Return the identity array.
docstring_tokens: Return the identity array .
function: def identity(n, dtype=None, *, like=None):
      """
      Return the identity array.
  
      The identity array is a square array with ones on
      the main diagonal.
  
      Parameters
      ----------
      n : int
          Number of rows (and columns) in `n` x `n` output.
      dtype : data-type, optional
          Data-type of the output.  Defaults to ``float``.
      ${ARRAY_FUNCTION_LIKE}
  
          .. versionadded:: 1.20.0
  
      Returns
      -------
      out : ndarray
          `n` x `n` array with its main diagonal set to one,
          and all other elements 0.
  
      Examples
      --------
      >>> np.identity(3)
      array([[1.,  0.,  0.],
             [0.,  1.,  0.],
             [0.,  0.,  1.]])
  
      """
      if like is not None:
          return _identity_with_like(n, dtype=dtype, like=like)
  
      from numpy import eye
      return eye(n, dtype=dtype, like=like)
function_tokens: def identity ( n , dtype = None , * , like = None ) : if like is not None : return _identity_with_like ( n , dtype = dtype , like = like ) from numpy import eye return eye ( n , dtype = dtype , like = like )