Python Numpy

 Python Numpy Important functions

  1. All() = Np.all  return  None of the element is zero.
  2. np.isreal() = Returns array is real or not
  3. np.isfinint() = Finiter or not
  4. np.iscomplex() = Complex or not
  5. np.isscalar() = Scalar or not
  6. np.greater(x,y) = Greater
  7. np.greater_equla() = Greater and equla , similerly for less
  8. np.zeros(no_0f_element) = create and 1d array zeros depending upon no of elements
  9. np.ones(no_of_element) = create and 1d array ones depending upon no of elements
  10. np.identity(size) = return the identity matrix of given size
  11. np.linspace(s,e,d) = it will return d no of equaliy distributed numbers between s and e
  12. np.diag(list of numbers) = set the list of numbers on the diagonal
  13. np.setdff1d(a,b) = return the unique elements from array a which are not in array b
  14. np.unique(a) = return all elemnents for array without repeating
  15. np.intersect1d(a,b) = return the intersaction of a,b similerly union
  16. np.in1d(a,b) = return that each element of array a in present in b or not
  17. np.nonzeros(condition) = returns the position of element which stisfy the condition in the array
  18. name_array.astype(data_type) = change the array into required data type eg. array.astype(float)
  19. np.full(shape of array, element) = it will return a new array of given shape filled with given element

Comments

Popular posts from this blog

#2 Library Management Software

#3 Water remainder Programme