Book Image

NumPy: Beginner's Guide

By : Ivan Idris
Book Image

NumPy: Beginner's Guide

By: Ivan Idris

Overview of this book

Table of Contents (21 chapters)
NumPy Beginner's Guide Third Edition
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
NumPy Functions' References
Index

Array elements extraction


The NumPy extract() function allows us to extract items from an array based on a condition. This function is similar to the where() function we encountered in Chapter 3, Getting Familiar with Commonly Used Functions. The special nonzero() function selects non-zero elements.