Welcome to pyglotaran_extras’s documentation!

pyglotaran-extras

PyPI version Conda Version Tests Documentation Status Binder

Ruff codecov Discord

Supplementary package for pyglotaran with (example) plotting code for use with the pyglotaran package. Can be installed as a python package or from sources.

Installation

Prerequisites:

  • Python 3.10 or 3.11

  • Python package pyglotaran v0.7.0 (or later)

Stable Release

To install pyglotaran-extras from PyPI, run this command in your terminal:

pip install pyglotaran-extras

If you want to install it via conda, you can run the following command:

conda install -c conda-forge pyglotaran-extras

From Source

To install pyglotaran-extras from sources, either clone this repository or download the latest release, then run this command in your terminal:

git clone https://github.com/glotaran/pyglotaran-extras.git
cd pyglotaran-extras
pip install -e .

or directly

pip install git+https://github.com/glotaran/pyglotaran-extras.git

Installation

Stable release

To install pyglotaran_extras, run this command in your terminal:

$ pip install pyglotaran_extras

This is the preferred method to install pyglotaran_extras, as it will always install the most recent stable release.

If you don’t have pip installed, this Python installation guide can guide you through the process.

From sources

The sources for pyglotaran_extras can be downloaded from the Github repo.

You can either clone the public repository:

$ git clone git://github.com/glotaran/pyglotaran-extras

Or download the tarball:

$ curl -OJL https://github.com/glotaran/pyglotaran-extras/tarball/main

Once you have a copy of the source, you can install it with:

$ pip install .

Usage

To use pyglotaran_extras in a project:

import pyglotaran_extras

Inner workings

This is the detailed documentation of the inner workings of pyglotaran_extras.

pyglotaran_extras

Pyglotaran extension package with convenience functionality such as plotting.

Contributing

Contributions are welcome, and they are greatly appreciated! Every little bit helps, and credit will always be given.

You can contribute in many ways:

Types of Contributions

Report Bugs

Report bugs at https://github.com/glotaran/pyglotaran-extras/issues.

If you are reporting a bug, please include:

  • Your operating system name and version.

  • Any details about your local setup that might be helpful in troubleshooting.

  • Detailed steps to reproduce the bug.

Fix Bugs

Look through the GitHub issues for bugs. Anything tagged with “bug” and “help wanted” is open to whoever wants to implement it.

Implement Features

Look through the GitHub issues for features. Anything tagged with “enhancement” and “help wanted” is open to whoever wants to implement it.

Write Documentation

pyglotaran_extras could always use more documentation, whether as part of the official pyglotaran_extras docs, in docstrings, or even on the web in blog posts, articles, and such.

Submit Feedback

The best way to send feedback is to file an issue at https://github.com/glotaran/pyglotaran-extras/issues.

If you are proposing a feature:

  • Explain in detail how it would work.

  • Keep the scope as narrow as possible, to make it easier to implement.

  • Remember that this is a volunteer-driven project, and that contributions are welcome :)

Get Started!

Ready to contribute? Here’s how to set up pyglotaran_extras for local development.

  1. Fork the pyglotaran-extras repo on GitHub.

  2. Clone your fork locally:

    $ git clone git@github.com:your_name_here/pyglotaran_extras.git
    
  3. Install your local copy into a virtualenv. Assuming you have virtualenvwrapper installed, this is how you set up your fork for local development:

    $ mkvirtualenv pyglotaran_extras
    $ cd pyglotaran-extras/
    $ pip install -e .
    
  4. install the pre-commit and pre-push hooks:

    $ pre-commit install && pre-commit install -t pre-push
    
  5. Create a branch for local development:

    $ git checkout -b name-of-your-bugfix-or-feature
    

    Now you can make your changes locally.

  6. Commit your changes and push your branch to GitHub:

    $ git add .
    $ git commit -m "Your detailed description of your changes."
    $ git push origin name-of-your-bugfix-or-feature
    
  7. Submit a pull request through the GitHub website.

Pull Request Guidelines

Before you submit a pull request, check that it meets these guidelines:

  1. The pull request should include tests.

  2. If the pull request adds functionality, the docs should be updated. Put your new functionality into a function with a docstring, and add the feature to the list in README.md.

  3. The pull request should work for Python 3.10 and 3.11. Check https://github.com/glotaran/pyglotaran-extras/actions and make sure that the tests pass for all supported Python versions.

Tips

To run a subset of tests:

$ pytest tests.test_pyglotaran_extras

Changelog

0.7.2 (2023-12-07)

  • 🧰👌 Switch tooling to ruff (#197)

  • 🩹 Fix crash when plotting spectral model result (#200)

  • 👷♻️ Use hatch as build backend (#204)

  • 🧰 Use black-pre-commit-mirror for 2x speedup (#205)

  • 🧰🚀 Use ruff for formatting (#214)

  • 👌 Use weighted residual instead of residual plots if present (#216)

  • 👌 Add color map arguments to plot_data_overview (#217)

  • 👌 Add das_cycler and svd_cycler to plot collection functions (#218)

  • 👌 Add use_svd_number switch to use SV number instead of index as label (#219)

  • 🩹 Fix use_svd_number not being passed on to plot_sv_data in plot_data_overview (#221)

  • 📦 Use trusted publisher workflow for publishing to PyPI (#222)

0.7.1 (2023-07-27)

  • 🩹 Fix crashes of plot_doas and plot_coherent_artifact for non dispersive IRF (#173, #182)

  • 👌 Add minor ticks to linlog plots (#183)

  • 🚧📦 Remove upper python version limit (#174)

  • ✨ Add add_subplot_labels function (#181)

0.7.0 (2023-04-15)

  • 👌 Fix typo in internal function name (#94)

  • ✨ Add IRF dispersion center plotting (#95)

  • 👌 Improve typing (#96)

  • 👌 Shift time axis by IRF location (#99)

  • 🩹🚇 Fix ‘Test pyglotaran dev’ CI step (#117)

  • 👌 Add option to deactivate data/residual plotting in overview plots (#118)

  • ✨ Add coherent artifact plot functionality (#123)

  • ✨ Add a-matrix inspection function (#124)

  • ✨ Add show_zero_line option to plot_overview and plot_fitted_traces (#128)

  • 🩹 Fix SVD vector labels always starting from zero (#133)

  • 👌 Make result input for plot_coherent_artifact more generic (#134)

  • ✨ Add plot_doas function that only plots DOAS related information (#135)

  • ✨ Shift irf derivatives in plot_coherent_artifact by irf position (#136)

  • 👌 Convert plot style Enums to StrEnums for ease of use (#144)

  • 🩹 Fix heading in show_a_matrixes for multiple a-matrixes per dataset (#148)

  • 👌 Add legend_format_string argument to plot_doas (#150)

  • 👌 Make plot_data_overview able to plot single trace data (#137)

  • 👌 Improve plot_doas default legend_format_string (#151)

  • 🩹⌨️ Fix figsize typing (#152)

  • 🩹📚 Fix search in docs (#157)

0.6.0 (2022-06-07)

  • 👌 Made adding a cycler to and axis opt out by using None by @s-weigand in #58

  • 🩹 Fix autogenerated title for concentration plot by @s-weigand in #63

  • 👌 Improve SVD plotting by @s-weigand in #64

  • 📚👌 Improve readme by @s-weigand in #69

  • 🔧🚇 Add sourcery-ai config by @s-weigand in #71

  • 🔧🩹 Remove github section in sourcery config due to bug in sourcery-ai by @s-weigand in #72

  • 👌 Improve legend placement in plot_data_overview by @s-weigand in #77

0.5.0 (2022-02-05)

  • First release on PyPI.

Indices and tables