python for data processing and plo3ng
play

Python for Data Processing and Plo3ng Han-Wei Shen The Ohio State - PowerPoint PPT Presentation

Python for Data Processing and Plo3ng Han-Wei Shen The Ohio State University (with help from Jonathan Woodring at Los Alamos NaConal Laboratory) What is Python? Fast code development and test A dynamically typed language You do not


  1. Python for Data Processing and Plo3ng Han-Wei Shen The Ohio State University (with help from Jonathan Woodring at Los Alamos NaConal Laboratory)

  2. What is Python? • Fast code development and test • A dynamically typed language – You do not need to declare the type of a variable • Syntax is very much C-like • A huge number of packages for doing almost everything (numpy, scipy, matplotlib, …) • AutomaCc memory management • FuncCons can be passed around as arguments • Can bind to C code easily for speed (from Jonathan Woodring, Los Alamos NL)

  3. Variable Assignment

  4. More Assignment

  5. Lists

  6. Slicing Lists

  7. Slicing Lists

  8. IteraCng Lists with Loops

  9. IteraCng Lists with Loops

  10. If-Then-Else

  11. Tuples are Immutable

  12. DicConaries

  13. FuncCon DefiniCons

  14. File I/O

  15. NumPy The most popular package for scienCfic compuCng • – Efficient N-dimensional arrays – Useful for linear algebra, data transformaCon etc. Get Numpy from hYp://www.scipy.org •

  16. NumPy The most popular package for scienCfic compuCng • – Efficient N-dimensional arrays – Useful for linear algebra, data transformaCon etc. Get Numpy from hYp://www.scipy.org •

  17. NumPy Slicing

  18. NumPy Array Reshaping

  19. NumPy Array BroadcasCng

  20. NumPy Linear Algebra

  21. NumPy I/O

  22. Matplotlib Python 2D plo3ng package that produces publicaCon quality figures • Get it from hYp://matplotlib.org •

  23. Line Graphs

  24. Images

  25. Histograms

Recommend


More recommend