mjoindices

This repository provides a Python implementation of the calculation algorithm for the OLR-based MJO index (OMI).

https://github.com/cghoffmann/mjoindices

Science Score: 59.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 11 DOI reference(s) in README
  • Academic publication links
    Links to: zenodo.org
  • Committers with academic emails
    2 of 5 committers (40.0%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (16.3%) to scientific vocabulary
Last synced: 6 months ago · JSON representation

Repository

This repository provides a Python implementation of the calculation algorithm for the OLR-based MJO index (OMI).

Basic Info
  • Host: GitHub
  • Owner: cghoffmann
  • License: gpl-3.0
  • Language: Python
  • Default Branch: master
  • Homepage:
  • Size: 442 MB
Statistics
  • Stars: 37
  • Watchers: 2
  • Forks: 15
  • Open Issues: 5
  • Releases: 9
Created over 6 years ago · Last pushed over 3 years ago
Metadata Files
Readme License Citation

README.md

mjoindices - A python package for calculating the Madden-Julian-Oscillation OMI index

DOI (paper) DOI

Overview

mjoindices is a Python package relevant for atmospheric scientists. It provides functionality to compute an index of the Madden-Julian-Oscillation (MJO), particularly the OLR-based MJO index (OMI).

Whereas the package name has been chosen to indicate that further MJO indices should be included in the future, the implementation is currently limited to the OMI algorithm.

A scientific description of the package is found in Hoffmann et al. (2021).

Citation

If you use mjoindices in published research, please cite the corresponding paper: Hoffmann, C.G., Kiladis, G.N., Gehne, M. and von Savigny, C., 2021. A Python Package to Calculate the OLR-Based Index of the Madden- Julian-Oscillation (OMI) in Climate Science and Weather Forecasting. Journal of Open Research Software, 9(1), p.9. DOI: http://doi.org/10.5334/jors.331

Please check our list of further scientific publications, on which the implementation of the package is based. It is likely that some of these publications should also be cited.

Contributors

Thanks for the contributions from the community!

Contributors

Requirements

mjoindices is written for Python 3 (version >= 3.7) and depends on the packages NumPy, Pandas, SciPy, and Matplotlib. It runs on Linux and Windows. Other operating systems have not been tested.

There are optional requirements, which can be installed along with mjoindices (see below)

Installation

mjoindices is available in the Python Package Index (PyPI). It can be installed using, e.g., pip.

pip3 install mjoindices

It can also be installed from the source, which is available on Zenodo and GitHub. Download the source, move into the directory containing the file setup.py and run

pip3 install .

The following optional dependency sets can additionaly be installed by adding ["setname"] behind the above commands: * *fullfunc: Install these packages to be sure that all options are really available. This might require a higher Python version than for the core functionality alone. OMI may still be computed without these additional packages, but the number of alternative approaches is limited. * *dev: packages that are needed for the further development, documentation and testing of mjoindices.

Examples:

pip3 install mjoindices[full_func]

or

pip3 install -e .[dev]

Getting started / examples

Note for experienced users: We have slightly changed the API for the EOF calculation with version 1.4. to be more flexible for changes in the future. Please read the API docs or compare your code with the current example. The old API is still working but will deprecate with one of the next releases. Adapting to the new interface will only take a few minutes.

There are three basic entry points, of which you should read the documentation:

After you have installed mjoindices, you can download an example from the source, which consists of two files:

  • recalculateoriginalomi.py: After downloading some data files, which are mentioned and linked in the source documentation of the example, you can run this example to recalculate the original OMI values. The script will save the computed Empirical Orthogonal Functions (EOFs) and the Principal Components (PCs) in two individual files, which can also be configured in the source code. In addition, it will save a few plots into a directory, which can also be configured in the source. These plots show the agreement with the original OMI values (slight deviations are expected due to numerical differences. This is explained in detail in the corresponding software meta paper).

Note that you can use this example also as a template to calculate OMI values with your own OLR data. In order to do that, you only have to adapt two parts of the code, which are also marked in the code documentation.

Note also that this script may run for one or two hours on common personal computer systems.

  • evaluateomireproduction.py: This script produces more detailed comparison plots and saves them into a directory. The script recalculateoriginalomi.py has to be run first, since the evaluation script is based on the saved results. As for recalculateoriginalomi.py, some file and directory names have to be adapted in the beginning of the code.

Both files are also available as Jupyter notebook files.

Documentation

The documentation is found on GitHub Pages and also in the docs folder of the source.

Automated testing

After you have installed mjoindices, you can also download unit and integration tests from the source to check your installation using pytest:

  • Download the complete test directory to you local file system.

  • Download the external input and reference data files from Zenodo. Details are given in a separate Readme file.

    • Note that some necessary data files are already included in the test directory in the repository. Make sure to download those files together with the tests. The data files on Zenodo are complementary and not included in the repository for reasons of file size and ownership.
  • Install the pytest package or simply install the mjoindices development dependencies with

    pip3 install mjoindices[dev]

  • Move into your local test directory and run

    pytest

  • In the case that some tests are failing with FileNotFoundErrors, it is likely that the package code is actually working, but that the test environment is not set up properly. You should check the following before contacting us:

    • Did you download the data files from the repository?
    • Did you download the data files from Zenodo?
    • Did you preserve the directory structure?
    • Did you execute pytest in the tests/ subdirectory (where pytest.ini is located)?
  • Note that the tests may run for a few hours on a common personal computer.

    • To get a quicker impression, you can omit slow tests by executing the following command. However, this will not check the core OMI computation, which is most important, of course.

      pytest -m 'not slow'

Owner

  • Name: Christoph G. Hoffmann
  • Login: cghoffmann
  • Kind: user
  • Location: Germany
  • Company: Universität Greifswald

GitHub Events

Total
  • Issues event: 2
  • Watch event: 7
  • Issue comment event: 9
  • Fork event: 1
Last Year
  • Issues event: 2
  • Watch event: 7
  • Issue comment event: 9
  • Fork event: 1

Committers

Last synced: almost 3 years ago

All Time
  • Total Commits: 273
  • Total Committers: 5
  • Avg Commits per committer: 54.6
  • Development Distribution Score (DDS): 0.333
Top Committers
Name Email Commits
Christoph Hoffmann c****n@u****e 182
Sarah Weidman 9****y@u****m 69
Mark Basham m****m@d****k 12
cghoffmann 5****n@u****m 9
Andreas a****n@d****m 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 6 months ago

All Time
  • Total issues: 9
  • Total pull requests: 9
  • Average time to close issues: 4 months
  • Average time to close pull requests: about 1 month
  • Total issue authors: 5
  • Total pull request authors: 4
  • Average comments per issue: 1.56
  • Average comments per pull request: 1.22
  • Merged pull requests: 9
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 2
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 2
  • Pull request authors: 0
  • Average comments per issue: 0.0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • cghoffmann (5)
  • syedhamidali (1)
  • felipeBianchini (1)
  • sweidy (1)
  • almmartinez (1)
Pull Request Authors
  • sweidy (4)
  • cghoffmann (3)
  • holmdk (1)
  • markbasham (1)
Top Labels
Issue Labels
enhancement (5) bug (2) invalid (1)
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • pypi 53 last-month
  • Total dependent packages: 0
  • Total dependent repositories: 1
  • Total versions: 10
  • Total maintainers: 1
pypi.org: mjoindices

Calculation of indices that describe the Madden-Julian-Oscillation (only OMI by now)

  • Versions: 10
  • Dependent Packages: 0
  • Dependent Repositories: 1
  • Downloads: 53 Last month
Rankings
Dependent packages count: 10.1%
Forks count: 10.9%
Stargazers count: 13.3%
Average: 17.6%
Dependent repos count: 21.6%
Downloads: 32.1%
Maintainers (1)
Last synced: 6 months ago

Dependencies

setup.py pypi
  • matplotlib *
  • netCDF4 *
  • numpy *
  • pandas *
  • pytest *
  • scipy *
Dockerfile docker
  • continuumio/miniconda3 latest build