7 Array-Oriented Programming with NumPy
Objectives
In this chapter you’ll:
Learn what arrays are and how they differ from lists.
Use the
numpy
module’s high-performancendarray
s.Compare list and
ndarray
performance with the IPython%timeit
magic.Use
ndarray
s to store and retrieve data efficiently.Create and initialize
ndarray
s.Refer to individual
ndarray
elements.Iterate through
ndarray
s.Create and manipulate multidimensional
ndarray
s.Perform common
ndarray
manipulations.Create and manipulate pandas one-dimensional
Series
and two-dimensionalDataFrame
s.Customize
Series
andDataFrame
indices.Calculate basic descriptive statistics for data in a
Series
and aDataFrame
.Customize floating-point number precision in pandas output formatting. ...
Get Intro to Python for Computer Science and Data Science: Learning to Program with AI, Big Data and The Cloud now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.