SHARE
TWEET

Untitled

a guest Sep 19th, 2019 72 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import numpy as np
  2.  
  3. array_a = np.array([[1,2,3],[4,5,6],[7,8,9]])
  4. array_b = np.array([[2,2,2],[3,4,5],[6,7,8]])
  5. print(array_a)
  6. print(array_b)
  7.  
  8. print(array_a.sum(axis=0))
  9.  
  10. print(array_a.ptp())
  11.  
  12. print(array_a.min(axis=1))
  13. print(array_a.max(axis=1))
  14. print(array_a.mean(axis=1))
  15.  
  16. # power
  17. print(np.power(array_a, array_b))
  18. array_c = np.array([[1,1,1],[2,2,2],[3,3,3]])
  19. print( array_a + array_b + array_c)
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top