NumPy is a valuable and efficient tool for dealing with large amounts of data. NumPy is quick; thus, it’s easy to work with a vast amount of data. Data analysis libraries like NumPy, SciPy, Pandas, and others have exploded in popularity due to the data science revolution. By Sonia Jessica.
# Accessing Range of Elements
# in array using slicing
val_mul=np.array([(3, 4, 2, 5),(3, 6, 2, 4),(1, 5, 2, 6)])
slice_val = val_mul[:2, :2]
print ("First 2 rows and columns of the array\n", slice_val)
NumPy implements multidimensional arrays and matrices as well as other complex data structures. These data structures help to compute arrays and matrices in the most efficient way possible. NumPy allows you to conduct mathematical and logical operations on arrays. Many other prominent Python packages, like pandas and matplotlib, are compatible with Numpy and use it.
The article then describes in some detail:
- What is a NumPy Array?
- Types of Numpy Array
- Accessing element in the Array
There are many code examples in article with explanation. Good read!
[Read More]