April 2016
Beginner
156 pages
3h 23m
English
NumPy has many universal functions (so-called ufuncs), so use them to your advantage to eliminate as many loops as you can to optimize your code. The ufuncs have a pretty good coverage in math, trigonometry, summary statistics, and comparison operations. For detailed ufunc lists, refer to the online documentation at http://docs.scipy.org/doc/numpy/reference/ufuncs.html .
Due to the large amount of ufuncs in NumPy, we can hardy cover all of them in a chapter. In this section, we only aim to understand how and why NumPy ufuncs should be used.
Most ufuncs are either unary or binary, which means that they can take only one or two arguments and apply them, element-wise or in mathematics; ...