Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
NumPy Essentials

You're reading from   NumPy Essentials Boost your scientific and analytic capabilities in no time at all by discovering how to build real-world applications with NumPy

Arrow left icon
Product type Paperback
Published in Apr 2016
Publisher
ISBN-13 9781784393670
Length 156 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Authors (4):
Arrow left icon
Jaidev Deshpande Jaidev Deshpande
Author Profile Icon Jaidev Deshpande
Jaidev Deshpande
 Chin Chin
Author Profile Icon Chin
Chin
Tanmay Dutta Tanmay Dutta
Author Profile Icon Tanmay Dutta
Tanmay Dutta
Shane Holloway Shane Holloway
Author Profile Icon Shane Holloway
Shane Holloway
Arrow right icon
View More author details
Toc

Table of Contents (11) Chapters Close

Preface 1. An Introduction to NumPy 2. The NumPy ndarray Object FREE CHAPTER 3. Using NumPy Arrays 4. NumPy Core and Libs Submodules 5. Linear Algebra in NumPy 6. Fourier Analysis in NumPy 7. Building and Distributing NumPy Code 8. Speeding Up NumPy with Cython 9. Introduction to the NumPy C-API 10. Further Reading

Getting started with numpy.ndarray

In this section, we will go over some of the internals of numpy ndarray, including its structure and behavior. Let's start. Type in the following statements in the IPython prompt:

In [1]: import numpy as np 
 
In [2]: x = np.array([[1,2,3],[2,3,4]]) 
 
In [3]: print(x)

NumPy shares the names of its functions with functions in other modules, such as the math module in the Python standard library. Using imports like the following there is not recommended:

from numpy import * 

As it may overwrite many functions that are already in the global namespace, which is not recommended. This may lead to unexpected behavior from your code and may introduce very subtle bugs in it . This may also create conflicts in the code itself, (example numPy has any and will cause conflicts with the system any keyword) and may cause confusion when reviewing or debugging a piece of code. Therefore, it is important and recommended to always follow the import numPy...

CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
NumPy Essentials
You have been reading a chapter from
NumPy Essentials
Published in: Apr 2016
Publisher:
ISBN-13: 9781784393670
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Modal Close icon
Modal Close icon