

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Community
Ask the community for help and clear up your study doubts
Discover the best universities in your country according to Docsity users
Free resources
Download our free guides on studying techniques, anxiety management strategies, and thesis advice from Docsity tutors
Numpy is a powerful python library designed for handling arrays and matrices, providing significant performance gains compared to python lists. With numpy, users can create, manipulate, and process multi-dimensional arrays, called ndarrays, which are stored in contiguous memory for optimal efficiency. This library also offers a range of supporting functions to simplify array operations.
Typology: Cheat Sheet
1 / 2
This page cannot be seen from the preview
Don't miss anything!
NumPy is a Python library used for working with arrays. NumPy stands for Numerical Python. In Python we have lists that serve the purpose of arrays, but they are slow to process. NumPy aims to provide an array object that is up to 50x faster than traditional Python lists. The array object in NumPy is called ndarray, it provides a lot of supporting functions that make working with ndarray very easy.
import numpy
Example import numpy arr = numpy.array([ 1 , 2 , 3 , 4 , 5 ]) print(arr) import numpy as np
Example import numpy as np arr = np.array([ 1 , 2 , 3 , 4 , 5 ]) print(arr)