Python for Water Resources Data Science

Python for Water Resources Data Science#

Welcome to the py4wrds course material!

About the py4wrds course#

This course is most relevant for folks who work with data, no matter their role. You’ll learn about fundamentals of Python and software development, and gain practice in using these skills for data science in the water resources domain.

Modules#

Code of conduct#

We will follow the SFS Code of Conduct throughout our workshop.

Source code#

The source code used to build this website can be found at the p4wrds GitHub repo.

Learning objectives#

  • Master common commands, data types, and data dictionaries.

  • Establish best coding practices for managing data and scripts.

  • Master “if/else” statements “for” and “while” loops, and other conditional statements.

  • Write clear functions and documentation to keep code clean and organized.

  • Modularize and disseminate clean codes to facilitate integration and re use with other projects.

  • Analyze model error metrics against observed data.

  • Understand and exploit object-oriented programming.

  • Work with key packages including pandas, numpy, matplotlib, jupyter, etc.

  • Set up and navigate Python integrated development environments such as Jupyter Notebook/Lab, Spyder, Visual Studio Code, Sublime Text, etc

  • Create, run, and disseminate virtual conda environments.

  • Use packages like Numpy, matplotlib, hydrostats, and Pulp for linear programming and matrix multiplication, specifically to optimize water allocations using DWRAT.

  • Develop plots and clear visualizations.

  • Use Jupyter Notebooks or other markdown tools to seamlessly embed Python code with documentation and publish it.

  • Use Git and GitHub for backing up code and collaboration with colleagues

License#

Software is open-source, provided under the MIT License.