Pages

Review of the book Numpy 1.5 - Beginner's Guide

Saturday, November 26, 2011

Hi all,

I'd like to share my review of the book Numpy 1.5 the Beginner's Guide by Ivan Idris, which is one of the latest books in a series of manuals covering scientific computing libraries written in Python.  This book covers the Numpy library for manipulating vectors and matrices and support for mathematical libraries.

Numpy 1.5  from Packt Publisher

Quick Review

The book is a great and useful resource for anyone who wants to explore further the Numpy scientific library since it covers almost all of the modules available at Numpy 1.5.  It comes with several examples, specially for finantial researchers and developers that work with finantial data. The author explored several modules using stocks and historical price data.  The authors explains each function or operation with code and the expected results, so the reader can follow precisely what's happening when he presents the modules. One of the values of the book is how it is organized: the step-by-step guide when he presents complex functions at Numpy, for example: add.reduceat, add.accumulate and add.reduce operators.
The part that I didn't like was about the exercises which was quite simple. I'd like to see deep exercises exploring the resources given at the book and I missed more information about NaN values. Also, I didn't  see information also about the functions squeeze, choose and about more complex structured arrays (arrays with tuples, etc.).

To sum up, I recommend this book for anyone whishing to learn about scientific computing with Python using the mathematical library Numpy which is a great alternative (and free !) for Matlab, Mathematica and other packages. I expect quite soon a book covering Scipy library also!  By the way, the finantial fans will love this book since it covers almost of the entire book with examples using finance data!

Review


The book starts with a step-by-step installation process of Numpy as also giving a litte introduction about what is Numpy, its history, etc.   I'd like to mention that even all the platforms covered at the book, Numpy is not so easy as mentioned to install at Mac OS.  The problem is that generally the developers don't use the built-in Python that comes with the Mac, since it is outdated (my Snow leopard comes with the Python 2.6.1). So when you install the new Python, that the problems come! Several compilation errors, messages that you can't understand, etc.  But if you go by using the MacPorts,  you will free of all these errors! ( After all the nightmare of the installation, I discovered the MacPorts :P).

The following chapters 2-4 presents the Numpy Fundamentals covering the array manipulations and most commonly used operations.  The books goes into a cyclic process, where each function that the author presents goes through an introduction about the problem to solve, the actions (how you with Numpy can solve), auxiliar numpy functions and operations and finally what just happened, that is, explain what he has done after showing the solution. The examples covered at book, most of them, are from finantial data and stock market values. An interesting choice since he used the same examples through the chapters in a progression and logical way.  Having each function and numpy featured described and explained made the book a good reference guide for someone using the library.  There were minor issues  related to the imports, he doesn't mention the imports in some examples,  for instance the numpy.loadtxt function when he uses the datetime module.  For a beginner that is studying Python for the first time, it may be harder to them to follow the examples, since he could not always tell where the functions or modules were coming from.

The second part of the book includes the matrices, universal functions, some scipy modules and the use of matplotlib and testing.  The chapter 5 covers the matrix module and universal functions such as add, divide, prod, sum and so on.  I missed some functions that weren't covered at this chapter such as numpy.choose or numpy.squeeze.  I believe the author didn't remember or didn't have space to mention these specific functions, but it does not prejudice at all the quality of the book. The chapter that I liked the most at the book was about testing. Several developers, special the scientific researchers are not used to test their code, so I believe it is a great chapter for anyone who wants to assure quality and avoid future bugs using Numpy testing modules.  The chapter should be more bigger and include more examples even creating test cases and tips for scientific developers.
Finally the last two chapters focus on plotting and Scipy integration. I think the plotting chapter should be at the beginning of the book, because he already uses lots of examples at the previous chapters with matplotlib and only at the end explain further about the library. The chapter is well-written and gives you sufficient content for beginning with Matplotlib. The last chapter covers the use of several scipy functions but it does not give deeper explanations about how it works as he did at the previous chapters with Numpy. However it gives several useful examples to work with integration, image processing and even optimization. Many developers will enjoy this extra-chapter covering the use of scipy+numpy.


Conclusions

 My overall impression of this book is that it could make a useful reference guide for Numpy. For finantial researchers and developers it will be a great book since it also covers lots of examples using finance data to present the numpy fundamentals.  There were minor issues related to Scipy and Matplotlib that should be more explained. For anyone who wants to start using Numpy it can a be an excellent book to begin, since it covers all the fundamentals steps with a cyclic progressive introduction of using the scientific packages in Python.

Regards,

Marcel Caraciolo

16 comments:

  1. Welcome to Wiztech Automation - Embedded System Training in Chennai. We have knowledgeable Team for Embedded Courses handling and we also are after Job Placements offer provide once your Successful Completion of Course. We are Providing on Microcontrollers such as 8051, PIC, AVR, ARM7, ARM9, ARM11 and RTOS. Free Accommodation, Individual Focus, Best Lab facilities, 100% Practical Training and Job opportunities.

    Embedded System Training in chennai
    Embedded System Training Institute in chennai
    Embedded Training in chennai
    Embedded Course in chennai
    Best Embedded System Training in chennai
    Best Embedded System Training Institute in chennai
    Best Embedded System Training Institutes in chennai
    Embedded Training Institute in chennai
    Embedded System Course in chennai
    Best Embedded System Training in chennai

    ReplyDelete
  2. This regression is quite used in several scenarios such as prediction of customer's propensity to purchase a product or cease a subscription in marketing applications and many others. visit this linkmsbi training In Chennai

    ReplyDelete
  3. this site share more valuable mathematical regression fiting data in a easy format thanks for such post .oracle dba training In Chennai

    ReplyDelete
  4. here i also wanted share ..i gather knowledge of predicted from human in heart attack update new prdicted information more ..sybase training In Chennai

    ReplyDelete
  5. if can gain knowledge of several predicted function thanks for such post.and more pls visit spring training In Chennai

    ReplyDelete
  6. Hai if our training additional way as (IT) trained as individual,you will be able to understand other applications more quickly and continue to build your skll set
    which will assist you in getting hi-tech industry jobs as possible in future courese of action..visit this blog webMethods-training in chennai

    ReplyDelete
  7. Really awesome blog. Your blog is really useful for me. Thanks for sharing this informative blog. Keep update your blog.
    QTP Training in Chennai

    ReplyDelete
  8. hai you have to learned to lot of information about oracle rac training Gain the knowledge and hands-on experience you need to successfully design, you have more information visit this site...
    oracle training in chennai

    ReplyDelete
  9. Looking for real-time training institue.Get details now may if share this link visit
    oracle training in chennai
    oraclechennai.com:

    ReplyDelete
  10. hai If you are interested in hyperion training, our real time working. so visit this site and get more details....
    hyperion Training in Chennai.
    hyperion training in chennai

    ReplyDelete
  11. WIZTECH Automation, Anna Nagar, Chennai, has earned reputation offering the best automation training in Chennai in the field of industrial automation. Flexible timings, hands-on-experience, 100% practical. The candidates are given enhanced job oriented practical training in all major brands of PLCs (AB, Keyence, ABB, GE-FANUC, OMRON, DELTA, SIEMENS, MITSUBISHI, SCHNEIDER, and MESSUNG)

    PLC training in chennai
    Automation training in chennai
    Best plc training in chennai
    PLC SCADA training in chennai
    Process automation training in chennai
    Final year eee projects in chennai
    VLSI training in chennai

    ReplyDelete
  12. Embedded system training: Wiztech Automation Provides Excellent training in embedded system training in Chennai - IEEE Projects - Mechanical projects in Chennai. Wiztech provide 100% practical training, Individual focus, Free Accommodation, Placement for top companies. The study also includes standard microcontrollers such as Intel 8051, PIC, AVR, ARM, ARMCotex, Arduino, etc.

    Embedded system training in chennai
    Embedded Course training in chennai
    Matlab training in chennai
    Android training in chennai
    LabVIEW training in chennai
    Robotics training in chennai
    Oracle training in chennai
    Final year projects in chennai
    Mechanical projects in chennai
    ece projects in chennai

    ReplyDelete
  13. Haryana HSSC Steno Typist Recruitment 2016


    Well written and useful stuff you share with us. I want more this kind of information from you.............

    ReplyDelete
  14. Naval Dockyard Visakhapatnam Tradesman Skilled Recruitment 2016

    Hi everyone, it’s my first visit at this site, and post is genuinely fruitful for me, keep up posting these types of articles.

    ReplyDelete
  15. Wiztech Automation Solutions is that the best PLC SCADA Marketing Communication Management: A Holistic Approach for Increased Profitability Training institute in Chennai and it's generating variety of PLC Engineers through its robust pillars like quality education, effective coaching, intimate with staffs to guide each student, spacious laboratories, Un-limited sensible sessions to boost their data as per the conditions of Automation trade.

    PLC, SCADA training in chennai
    PLC training in chennai
    Automation training in chennai

    ReplyDelete