Coder Social home page Coder Social logo

pythoninchemistry / intro_python_chemists Goto Github PK

View Code? Open in Web Editor NEW
22.0 22.0 6.0 9.89 MB

An open-source, online textbook introducing Python programming to chemistry students

Home Page: https://pythoninchemistry.org/intro_python_chemists

License: BSD 3-Clause "New" or "Revised" License

Ruby 0.05% Makefile 0.07% TeX 0.44% HTML 2.55% CSS 0.01% JavaScript 1.67% Jupyter Notebook 85.96% Python 0.46% SCSS 8.79%

intro_python_chemists's People

Contributors

alexsquires avatar arm61 avatar bjmorgan avatar glass-w avatar j-m-dean avatar rmeli avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

intro_python_chemists's Issues

Classes

Write a section introducing classes:

  • class variables
  • class methods/functions
  • the @property decorator
  • docstrings for classes

reading documentation

Before introducing writing documentation (#13), we should have a section on reading documentation (the ? in Jupyter and finding docs online).

Add William to .zenodo.json

@WG150 now that you have contributed can you add yourself to the .zenodo.json so that when the next release is minted you are recognised appropriately!

Custom modules

Write a section showing how custom modules (your own python code in a .py file) can be imported.

Debugging

Write a section discussing common debugging practices, including how best to read a python traceback. This can link with the testing section.

Model answers for longer exercises

In #58, @j-m-dean has raised the question "Are model solutions provided for the longer exercises?".

This issue is to get peoples feeling on that.

My preference would be to give answers but not solutions that are only accessible by clicking a link. My rationale is that in programming there are infinite ways to solve a given problem so I don't want to pigeonhole people with one solution, additionally frequently all you want is to know that you got the right answer.

Thoughts?

CI doesn't work for jupyter-book==0.6.5

The circleci falls down with the most recent release of jupyter-book, claiming that it cannot find the toc.

Couldn't find a Table of Contents file. To auto-generate one, run

jupyter-book toc .

But there is a toc. Need to work out why this is, for now jupyter-book==0.6.4 is the the requirements.txt

License

Should a (permissive) license be added to this repository?

Documentation

Write a section introducing documentation:

  • comments
  • docstrings (also covered in functions)

This should include the comments from @acnash on issue #5

Loops

Write a section introducing:

  • for loops
  • while loops

This should include some discussion of the range() iterator, the difference between the loops and break/continue.

Update style guide

Update style guide to promote the use of non-gendered pronouns ie the use of they in preference to him/her.

ir_spectra

Write ir_spectra section - based on data analysis problem from CH40208

Add Rocco to .zenodo.json

@RMeli now that you have contributed can you add yourself to the .zenodo.json so that when the next release is minted you are recognised appropriately!

Is LaTeX discussed at all?

What is the project position on LaTeX? LaTeX for chemistry in itself it could easily be (and probably is) the subject another book. However it's very useful when it comes to e.g. axes labels, is it going to be introduced anywhere?

Order of basics section

Would it not be an easier learning curve to change the order of the basics section from

  • url: /basics/types
    • url: /basics/collections
    • url: /basics/numpy_arrays
    • url: /basics/functions
    • url: /basics/flow_control
    • url: /basics/and_or
    • url: /basics/loops

to

  • url: /basics/types
    • url: /basics/collections
    • url: /basics/flow_control
    • url: /basics/and_or
    • url: /basics/loops
    • url: /basics/numpy_arrays
    • url: /basics/functions

Arrays and functions before flow control, loops, and logic seems a bit odd to me. Thoughts?

Use an assigned variable in Types

In the Types section, there is not an discussion of using a variable. For example, in a mathematical operation.

This would help understanding of variables as a whole to include.

Testing

Write a section introducing testing, discussing it's importance in code reliability. Might also include a discussion about test driven development.

Units and uncertainties

Write a section that will introduce the pint and uncertainties libraries for working with data.

Advanced plotting contents

Depending on exactly what goes in surface_plots I propose covering:

  • object oriented plotting, building towards a figure with multiple subplots
  • customizing plots, building towards the concept of an .rc file
  • brief intro to LaTeX, purely in the context of conveying data in matplotlib

Reading and writing to files

Write a section discussing IO:

  • python's build in open stuff
  • NumPy's np.loadtxt

I (personally) don't think there is scope for pandas here but I am happy to have my mind changed.

NumPy arrays

Write a section introducing NumPy arrays. Ideally covering, lightly, that these arrays are:

  • of fixed type
  • make numerical operations faster
  • able to perform vectorised operations

Develop a Table of Contents

The first draft Table of Contents is now online in the _data/toc.yml. However, we want to get more ideas for sections and chapters to include.

Please comment below with potential areas for inclusion (or areas currently included that should be removed).

Any and all ideas are welcome!

Packages

Write a section introducing packages:

  • discuss pip install of packages
  • explain package importing
  • explain importing a single module or function from a package

Also discuss the importance of the package infrastructure to the python language.

And and or operations

Write a section to introduce and and or logical, showing it in the context of flow control

Collections

Write a section covering collections:

  • tuples
  • lists
  • dictionaries

Simple plots

Write a section on 1d plotting:

  • plt.plot()
  • plt.errorbar()
  • multiple lines on a plot

Flow control

Write a section that will cover:

  • if
  • else
  • elif

As well as introducing why this is useful.

Statistical analysis

Write a section introduction how numpy and scipy can be used for basic stats

  • mean
  • std
  • percentiles

Custom packages

Write a section about creating python packages:

  • sharing them on pypi
  • setup.py
  • publishing packages

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.