mgnify-methods 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (101) hide show
  1. mgnify_methods-0.1.0/.github/FUNDING.yml +15 -0
  2. mgnify_methods-0.1.0/.github/ISSUE_TEMPLATE//360/237/220/233-bug-report.md +30 -0
  3. mgnify_methods-0.1.0/.github/ISSUE_TEMPLATE//360/237/222/241-feature-request.md +21 -0
  4. mgnify_methods-0.1.0/.github/workflows/test-deploy.yml +104 -0
  5. mgnify_methods-0.1.0/.gitignore +216 -0
  6. mgnify_methods-0.1.0/.python-version +1 -0
  7. mgnify_methods-0.1.0/.readthedocs.yaml +23 -0
  8. mgnify_methods-0.1.0/LICENSE +21 -0
  9. mgnify_methods-0.1.0/Makefile +50 -0
  10. mgnify_methods-0.1.0/PKG-INFO +116 -0
  11. mgnify_methods-0.1.0/README.md +78 -0
  12. mgnify_methods-0.1.0/assets/data_analysis_pipeline.html +191 -0
  13. mgnify_methods-0.1.0/assets/data_analysis_pipeline.mmd +60 -0
  14. mgnify_methods-0.1.0/assets/diagram.svg +1 -0
  15. mgnify_methods-0.1.0/assets/diagram_small.svg +946 -0
  16. mgnify_methods-0.1.0/assets/diagram_working.svg +288 -0
  17. mgnify_methods-0.1.0/assets/figs/mgnify_banner.png +0 -0
  18. mgnify_methods-0.1.0/assets/mermaid_config.json +4 -0
  19. mgnify_methods-0.1.0/configs/paper.json +159 -0
  20. mgnify_methods-0.1.0/configs/small.json +137 -0
  21. mgnify_methods-0.1.0/data/mgnify_data/ERP003634_taxonomy_abundances_SSU_v5.0.tsv +498 -0
  22. mgnify_methods-0.1.0/data/mgnify_data/ERP106348_taxonomy_abundances_SSU_v5.0.tsv +1506 -0
  23. mgnify_methods-0.1.0/data/mgnify_data/ERP122219_taxonomy_abundances_SSU_v5.0.tsv +2504 -0
  24. mgnify_methods-0.1.0/data/mgnify_data/ERP124424_taxonomy_abundances_SSU_v5.0.tsv +1982 -0
  25. mgnify_methods-0.1.0/data/mgnify_data/ERP124431_taxonomy_abundances_SSU_v5.0.tsv +1709 -0
  26. mgnify_methods-0.1.0/data/mgnify_data/ERP140185_taxonomy_abundances_SSU_v5.0.tsv +4317 -0
  27. mgnify_methods-0.1.0/data/mgnify_data/ERP144826_taxonomy_abundances_SSU_v5.0.tsv +2242 -0
  28. mgnify_methods-0.1.0/data/mgnify_data/ERP151329_taxonomy_abundances_SSU_v5.0.tsv +1429 -0
  29. mgnify_methods-0.1.0/data/mgnify_data/SRP237882_taxonomy_abundances_SSU_v5.0.tsv +3485 -0
  30. mgnify_methods-0.1.0/data/mgnify_data/SRP334933_taxonomy_abundances_SSU_v5.0.tsv +119 -0
  31. mgnify_methods-0.1.0/data/parquet_files/metagoflow_analyses.LSU.parquet +0 -0
  32. mgnify_methods-0.1.0/data/parquet_files/metagoflow_analyses.SSU.parquet +0 -0
  33. mgnify_methods-0.1.0/data/parquet_files/metagoflow_analyses.go.parquet +0 -0
  34. mgnify_methods-0.1.0/data/parquet_files/metagoflow_analyses.go_slim.parquet +0 -0
  35. mgnify_methods-0.1.0/data/parquet_files/metagoflow_analyses.ips.parquet +0 -0
  36. mgnify_methods-0.1.0/data/parquet_files/metagoflow_analyses.ko.parquet +0 -0
  37. mgnify_methods-0.1.0/data/parquet_files/metagoflow_analyses.pfam.parquet +0 -0
  38. mgnify_methods-0.1.0/data/shipment_b1b2_181.csv +182 -0
  39. mgnify_methods-0.1.0/docs/source/api.md +8 -0
  40. mgnify_methods-0.1.0/docs/source/conf.py +38 -0
  41. mgnify_methods-0.1.0/docs/source/index.md +23 -0
  42. mgnify_methods-0.1.0/docs/source/installation.md +21 -0
  43. mgnify_methods-0.1.0/notebooks/01_mgnify_rarefaction_test.ipynb +17850 -0
  44. mgnify_methods-0.1.0/notebooks/02_mgnify_rarefaction.ipynb +12271 -0
  45. mgnify_methods-0.1.0/notebooks/03_mgnify_rarefaction_fast.ipynb +8362 -0
  46. mgnify_methods-0.1.0/notebooks/04_mgnify_rarefaction_bacteria_multiple_studies.ipynb +22372 -0
  47. mgnify_methods-0.1.0/notebooks/05_bacteria_multiple_studies.ipynb +1886 -0
  48. mgnify_methods-0.1.0/notebooks/06_multiple_studies_alpha.ipynb +3995 -0
  49. mgnify_methods-0.1.0/notebooks/07_multiple_studies_alpha_emo-bon.ipynb +4133 -0
  50. mgnify_methods-0.1.0/notebooks/07_multiple_studies_beta_emo-bon.ipynb +1337 -0
  51. mgnify_methods-0.1.0/notebooks/README.md +20 -0
  52. mgnify_methods-0.1.0/notebooks/get_ena_metadata.ipynb +618 -0
  53. mgnify_methods-0.1.0/notebooks/test_mgnify_oop.ipynb +1540 -0
  54. mgnify_methods-0.1.0/pyproject.toml +85 -0
  55. mgnify_methods-0.1.0/scripts/ad_hoc_analysis.py +37 -0
  56. mgnify_methods-0.1.0/scripts/alpha_diversity_heatmaps.py +149 -0
  57. mgnify_methods-0.1.0/scripts/beta_diversity_heatmaps.py +155 -0
  58. mgnify_methods-0.1.0/scripts/deseq2_plots.py +280 -0
  59. mgnify_methods-0.1.0/scripts/deseq2_stats.py +103 -0
  60. mgnify_methods-0.1.0/scripts/mgnify_rarefaction.py +126 -0
  61. mgnify_methods-0.1.0/scripts/paper_run.py +157 -0
  62. mgnify_methods-0.1.0/scripts/post_analysis.py +29 -0
  63. mgnify_methods-0.1.0/src/mgnify_methods/__init__.py +12 -0
  64. mgnify_methods-0.1.0/src/mgnify_methods/metacomp/__init__.py +0 -0
  65. mgnify_methods-0.1.0/src/mgnify_methods/metacomp/diversity.py +268 -0
  66. mgnify_methods-0.1.0/src/mgnify_methods/metacomp/rarefaction.py +110 -0
  67. mgnify_methods-0.1.0/src/mgnify_methods/metacomp/transforms.py +81 -0
  68. mgnify_methods-0.1.0/src/mgnify_methods/paper_modules.py +806 -0
  69. mgnify_methods-0.1.0/src/mgnify_methods/stats.py +474 -0
  70. mgnify_methods-0.1.0/src/mgnify_methods/tables/__init__.py +11 -0
  71. mgnify_methods-0.1.0/src/mgnify_methods/tables/sources/__init__.py +0 -0
  72. mgnify_methods-0.1.0/src/mgnify_methods/tables/sources/converters.py +42 -0
  73. mgnify_methods-0.1.0/src/mgnify_methods/tables/sources/detectors.py +105 -0
  74. mgnify_methods-0.1.0/src/mgnify_methods/tables/sources/handlers.py +71 -0
  75. mgnify_methods-0.1.0/src/mgnify_methods/tables/sources/validators.py +38 -0
  76. mgnify_methods-0.1.0/src/mgnify_methods/tables/tables.py +180 -0
  77. mgnify_methods-0.1.0/src/mgnify_methods/taxonomy.py +449 -0
  78. mgnify_methods-0.1.0/src/mgnify_methods/utils/__init__.py +1 -0
  79. mgnify_methods-0.1.0/src/mgnify_methods/utils/api.py +117 -0
  80. mgnify_methods-0.1.0/src/mgnify_methods/utils/io.py +839 -0
  81. mgnify_methods-0.1.0/src/mgnify_methods/utils/logging.py +91 -0
  82. mgnify_methods-0.1.0/src/mgnify_methods/utils/plot.py +742 -0
  83. mgnify_methods-0.1.0/tests/ERP124424_taxonomy_abundances_SSU_v5.0.tsv +1982 -0
  84. mgnify_methods-0.1.0/tests/SRP237882_taxonomy_abundances_SSU_v5.0.tsv +3485 -0
  85. mgnify_methods-0.1.0/tests/__init__.py +1 -0
  86. mgnify_methods-0.1.0/tests/test_basic.py +59 -0
  87. mgnify_methods-0.1.0/tests/test_metacomp.py +134 -0
  88. mgnify_methods-0.1.0/tests/test_oop.py +59 -0
  89. mgnify_methods-0.1.0/tests/test_plot_utils.py +32 -0
  90. mgnify_methods-0.1.0/tests/test_sources_utils.py +53 -0
  91. mgnify_methods-0.1.0/tests/test_tables_core.py +59 -0
  92. mgnify_methods-0.1.0/tests/test_taxonomy_utils.py +79 -0
  93. mgnify_methods-0.1.0/tests/test_utils_api.py +89 -0
  94. mgnify_methods-0.1.0/tests/test_utils_api_session.py +34 -0
  95. mgnify_methods-0.1.0/tests/test_utils_io.py +387 -0
  96. mgnify_methods-0.1.0/tests/test_utils_logging.py +25 -0
  97. mgnify_methods-0.1.0/tests/test_utils_plot_mean.py +27 -0
  98. mgnify_methods-0.1.0/tests/test_utils_plot_save.py +21 -0
  99. mgnify_methods-0.1.0/tests/test_utils_plot_taxonomy.py +35 -0
  100. mgnify_methods-0.1.0/tests/test_utils_plot_violin.py +25 -0
  101. mgnify_methods-0.1.0/uv.lock +4067 -0
@@ -0,0 +1,15 @@
1
+ # These are supported funding model platforms
2
+
3
+ github: [palec87]
4
+ patreon: # Replace with a single Patreon username
5
+ open_collective: # Replace with a single Open Collective username
6
+ ko_fi: # Replace with a single Ko-fi username
7
+ tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8
+ community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9
+ liberapay: # Replace with a single Liberapay username
10
+ issuehunt: # Replace with a single IssueHunt username
11
+ lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
12
+ polar: # Replace with a single Polar username
13
+ buy_me_a_coffee: # Replace with a single Buy Me a Coffee username
14
+ thanks_dev: # Replace with a single thanks.dev username
15
+ custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
@@ -0,0 +1,30 @@
1
+ ---
2
+ name: "\U0001F41B Bug report"
3
+ about: Create a report to help us improve
4
+ title: "[BUG]"
5
+ labels: ''
6
+ assignees: ''
7
+
8
+ ---
9
+
10
+ ✏️ **Describe the bug**
11
+ A clear and concise description of what the bug is.
12
+
13
+ 👯 **To Reproduce**
14
+ Steps to reproduce the behavior:
15
+ 1. Go to '...'
16
+ 2. run command '...'
17
+ 3. function error '...'
18
+
19
+ 🌈 **Expected behavior**
20
+ Description of what you expected to happen.
21
+
22
+ 📸 **Screenshots**
23
+ If applicable, add screenshots to help explain your problem.
24
+
25
+ ℹ️ **System information:**
26
+ - OS: [e.g. iOS]
27
+ - python version: [e.g. 3.12]
28
+
29
+ ➕ **Additional context**
30
+ Add any other context about the problem here.
@@ -0,0 +1,21 @@
1
+ ---
2
+ name: "\U0001F4A1 Feature request"
3
+ about: Suggest an idea for this project
4
+ title: "[Feature]"
5
+ labels: ''
6
+ assignees: ''
7
+
8
+ ---
9
+
10
+ ❓ **Is your feature request related to a problem?**
11
+ What the problem is. Ex. I'm always frustrated when [...]
12
+ Link to an open issue: [...]
13
+
14
+ ❗ **Describe the solution you'd like**
15
+ A clear and concise description of what you want to happen.
16
+
17
+ ❔ **Describe alternatives you've considered**
18
+ A clear and concise description of any alternative solutions or features you've considered.
19
+
20
+ **Additional context**
21
+ Add any other context or screenshots about the feature request here.
@@ -0,0 +1,104 @@
1
+ # This workflows will upload a Python Package using Twine when a release is created
2
+ # For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
3
+
4
+ name: tests
5
+
6
+ on:
7
+ push:
8
+ branches:
9
+ - main
10
+ tags:
11
+ - "v*" # Push events to matching v*, i.e. v1.0, v20.15.10
12
+ pull_request:
13
+ branches:
14
+ - main
15
+ workflow_dispatch:
16
+
17
+ jobs:
18
+ test:
19
+ name: ${{ matrix.platform }} py${{ matrix.python-version }}
20
+ runs-on: ${{ matrix.platform }}
21
+ timeout-minutes: 30
22
+ strategy:
23
+ matrix:
24
+ platform: [ubuntu-latest, windows-latest, macos-latest] # is not tested atm
25
+ python-version: ["3.12"]
26
+
27
+ steps:
28
+ - uses: actions/checkout@v4
29
+
30
+ - name: Set up Python ${{ matrix.python-version }}
31
+ uses: actions/setup-python@v5
32
+ with:
33
+ python-version: ${{ matrix.python-version }}
34
+
35
+ - name: Set up uv
36
+ uses: astral-sh/setup-uv@v5
37
+
38
+ - name: Install dependencies
39
+ run: |
40
+ uv sync --extra dev
41
+ uv pip install git+https://github.com/fair-ease/py-udal-mgo.git
42
+
43
+ # this runs the platform-specific tests declared in tox.ini
44
+ - name: Test with pytest
45
+ uses: aganders3/headless-gui@v2
46
+ with:
47
+ run: uv run pytest -v --color=yes --cov=src --cov-report=xml
48
+ env:
49
+ PLATFORM: ${{ matrix.platform }}
50
+ MPLBACKEND: Agg
51
+
52
+ # - name: Codecov
53
+ # uses: codecov/codecov-action@v5.4.2
54
+ # with:
55
+ # token: ${{ secrets.CODECOV_TOKEN }}
56
+
57
+ build:
58
+ name: Build distribution 📦
59
+ runs-on: ubuntu-latest
60
+ needs:
61
+ - test
62
+
63
+ steps:
64
+ - uses: actions/checkout@v4
65
+ with:
66
+ persist-credentials: false
67
+ - name: Set up Python
68
+ uses: actions/setup-python@v5
69
+ with:
70
+ python-version: "3.x"
71
+ - name: Install pypa/build
72
+ run: >-
73
+ python3 -m
74
+ pip install
75
+ build
76
+ --user
77
+ - name: Build a binary wheel and a source tarball
78
+ run: python3 -m build
79
+ - name: Store the distribution packages
80
+ uses: actions/upload-artifact@v4
81
+ with:
82
+ name: python-package-distributions
83
+ path: dist/
84
+
85
+ publish-to-pypi:
86
+ name: Publish Python distribution to PyPI
87
+ if: startsWith(github.ref, 'refs/tags/') # only publish to PyPI on tag pushes
88
+ needs:
89
+ - build
90
+ runs-on: ubuntu-latest
91
+ environment:
92
+ name: pypi
93
+ url: https://pypi.org/project/mgnify-methods/ # Replace <package-name> with your PyPI project name
94
+ permissions:
95
+ id-token: write # IMPORTANT: mandatory for trusted publishing
96
+
97
+ steps:
98
+ - name: Download all the dists
99
+ uses: actions/download-artifact@v4
100
+ with:
101
+ name: python-package-distributions
102
+ path: dist/
103
+ - name: Publish distribution to PyPI
104
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,216 @@
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+ *.py[codz]
4
+ *$py.class
5
+
6
+ # C extensions
7
+ *.so
8
+
9
+ # Distribution / packaging
10
+ .Python
11
+ build/
12
+ develop-eggs/
13
+ dist/
14
+ downloads/
15
+ eggs/
16
+ .eggs/
17
+ lib/
18
+ lib64/
19
+ parts/
20
+ sdist/
21
+ var/
22
+ wheels/
23
+ share/python-wheels/
24
+ *.egg-info/
25
+ .installed.cfg
26
+ *.egg
27
+ MANIFEST
28
+
29
+ # PyInstaller
30
+ # Usually these files are written by a python script from a template
31
+ # before PyInstaller builds the exe, so as to inject date/other infos into it.
32
+ *.manifest
33
+ *.spec
34
+
35
+ # Installer logs
36
+ pip-log.txt
37
+ pip-delete-this-directory.txt
38
+
39
+ # Unit test / coverage reports
40
+ htmlcov/
41
+ .tox/
42
+ .nox/
43
+ .coverage
44
+ .coverage.*
45
+ .cache
46
+ nosetests.xml
47
+ coverage.xml
48
+ *.cover
49
+ *.py.cover
50
+ .hypothesis/
51
+ .pytest_cache/
52
+ cover/
53
+
54
+ # Translations
55
+ *.mo
56
+ *.pot
57
+
58
+ # Django stuff:
59
+ *.log
60
+ local_settings.py
61
+ db.sqlite3
62
+ db.sqlite3-journal
63
+
64
+ # Flask stuff:
65
+ instance/
66
+ .webassets-cache
67
+
68
+ # Scrapy stuff:
69
+ .scrapy
70
+
71
+ # Sphinx documentation
72
+ docs/_build/
73
+
74
+ # PyBuilder
75
+ .pybuilder/
76
+ target/
77
+
78
+ # Jupyter Notebook
79
+ .ipynb_checkpoints
80
+
81
+ # IPython
82
+ profile_default/
83
+ ipython_config.py
84
+
85
+ # pyenv
86
+ # For a library or package, you might want to ignore these files since the code is
87
+ # intended to run in multiple environments; otherwise, check them in:
88
+ # .python-version
89
+
90
+ # pipenv
91
+ # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
92
+ # However, in case of collaboration, if having platform-specific dependencies or dependencies
93
+ # having no cross-platform support, pipenv may install dependencies that don't work, or not
94
+ # install all needed dependencies.
95
+ #Pipfile.lock
96
+
97
+ # UV
98
+ # Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
99
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
100
+ # commonly ignored for libraries.
101
+ #uv.lock
102
+
103
+ # poetry
104
+ # Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
105
+ # This is especially recommended for binary packages to ensure reproducibility, and is more
106
+ # commonly ignored for libraries.
107
+ # https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
108
+ #poetry.lock
109
+ #poetry.toml
110
+
111
+ # pdm
112
+ # Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
113
+ # pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
114
+ # https://pdm-project.org/en/latest/usage/project/#working-with-version-control
115
+ #pdm.lock
116
+ #pdm.toml
117
+ .pdm-python
118
+ .pdm-build/
119
+
120
+ # pixi
121
+ # Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
122
+ #pixi.lock
123
+ # Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
124
+ # in the .venv directory. It is recommended not to include this directory in version control.
125
+ .pixi
126
+
127
+ # PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
128
+ __pypackages__/
129
+
130
+ # Celery stuff
131
+ celerybeat-schedule
132
+ celerybeat.pid
133
+
134
+ # SageMath parsed files
135
+ *.sage.py
136
+
137
+ # Environments
138
+ .env
139
+ .envrc
140
+ .venv
141
+ env/
142
+ venv/
143
+ ENV/
144
+ env.bak/
145
+ venv.bak/
146
+
147
+ # Spyder project settings
148
+ .spyderproject
149
+ .spyproject
150
+
151
+ # Rope project settings
152
+ .ropeproject
153
+
154
+ # mkdocs documentation
155
+ /site
156
+
157
+ # mypy
158
+ .mypy_cache/
159
+ .dmypy.json
160
+ dmypy.json
161
+
162
+ # Pyre type checker
163
+ .pyre/
164
+
165
+ # pytype static type analyzer
166
+ .pytype/
167
+
168
+ # Cython debug symbols
169
+ cython_debug/
170
+
171
+ # PyCharm
172
+ # JetBrains specific template is maintained in a separate JetBrains.gitignore that can
173
+ # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
174
+ # and can be added to the global gitignore or merged into this file. For a more nuclear
175
+ # option (not recommended) you can uncomment the following to ignore the entire idea folder.
176
+ #.idea/
177
+
178
+ # Abstra
179
+ # Abstra is an AI-powered process automation framework.
180
+ # Ignore directories containing user credentials, local state, and settings.
181
+ # Learn more at https://abstra.io/docs
182
+ .abstra/
183
+
184
+ # Visual Studio Code
185
+ # Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
186
+ # that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
187
+ # and can be added to the global gitignore or merged into this file. However, if you prefer,
188
+ # you could uncomment the following to ignore the entire vscode folder
189
+ # .vscode/
190
+
191
+ # Ruff stuff:
192
+ .ruff_cache/
193
+
194
+ # PyPI configuration file
195
+ .pypirc
196
+
197
+ # Cursor
198
+ # Cursor is an AI-powered code editor. `.cursorignore` specifies files/directories to
199
+ # exclude from AI features like autocomplete and code analysis. Recommended for sensitive data
200
+ # refer to https://docs.cursor.com/context/ignore-files
201
+ .cursorignore
202
+ .cursorindexingignore
203
+
204
+ # Marimo
205
+ marimo/_static/
206
+ marimo/_lsp/
207
+ __marimo__/
208
+
209
+ .vscode/
210
+ .venv/
211
+ notebooks/analysis_*/
212
+ notebooks/MGYS00006680/
213
+ outputs/
214
+ paper/
215
+
216
+ .history/
@@ -0,0 +1 @@
1
+ 3.12
@@ -0,0 +1,23 @@
1
+ # .readthedocs.yaml
2
+ # Read the Docs configuration file
3
+ # See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
4
+
5
+ version: 2
6
+
7
+ build:
8
+ os: ubuntu-22.04
9
+ tools:
10
+ python: "3.12"
11
+ jobs:
12
+ post_install:
13
+ - uv sync --extra docs
14
+
15
+ sphinx:
16
+ configuration: docs/source/conf.py
17
+
18
+ python:
19
+ install:
20
+ - method: pip
21
+ path: .
22
+ extra_requirements:
23
+ - docs
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 David Paleček
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,50 @@
1
+ .PHONY: help install dev-install test coverage lint format clean docs build
2
+
3
+ help: ## Show this help message
4
+ @echo 'Usage: make [target]'
5
+ @echo ''
6
+ @echo 'Available targets:'
7
+ @awk 'BEGIN {FS = ":.*?## "} /^[a-zA-Z_-]+:.*?## / {printf " %-20s %s\n", $$1, $$2}' $(MAKEFILE_LIST)
8
+
9
+ install: ## Install the package
10
+ uv sync && \
11
+ uv pip install git+https://github.com/fair-ease/py-udal-mgo.git
12
+
13
+ dev-install: ## Install the package with development dependencies
14
+ uv sync --extra dev --extra docs && \
15
+ uv pip install git+https://github.com/fair-ease/py-udal-mgo.git && \
16
+ uv run python -m ipykernel install --user --name mgnify-methods --display-name "mgnify-methods"
17
+
18
+ test: ## Run tests
19
+ uv run pytest tests/
20
+
21
+ coverage: ## Run tests with coverage report
22
+ uv run pytest --cov=src --cov-report=html --cov-report=term tests/
23
+
24
+ lint: ## Run linters (ruff and mypy)
25
+ uv run ruff check src tests
26
+ uv run mypy src
27
+
28
+ format: ## Format code with ruff
29
+ uv run ruff format src tests
30
+ uv run ruff check --fix src tests
31
+
32
+ clean: ## Clean build artifacts and cache files
33
+ rm -rf build/
34
+ rm -rf dist/
35
+ rm -rf *.egg-info
36
+ rm -rf .pytest_cache/
37
+ rm -rf .mypy_cache/
38
+ rm -rf .ruff_cache/
39
+ rm -rf htmlcov/
40
+ rm -rf .coverage
41
+ find . -type d -name __pycache__ -exec rm -rf {} + 2>/dev/null || true
42
+ find . -type f -name "*.pyc" -delete
43
+
44
+ docs: ## Build documentation
45
+ cd docs && uv run sphinx-build -b html source _build/html
46
+
47
+ build: ## Build the package
48
+ uv build
49
+
50
+ .DEFAULT_GOAL := help
@@ -0,0 +1,116 @@
1
+ Metadata-Version: 2.4
2
+ Name: mgnify-methods
3
+ Version: 0.1.0
4
+ Summary: Support methods and classes for the Biodiversity studies on Mgnify metagenomes
5
+ Author-email: palec87 <palec87@users.noreply.github.com>
6
+ License-File: LICENSE
7
+ Requires-Python: >=3.12
8
+ Requires-Dist: biopython>=1.81.0
9
+ Requires-Dist: ipykernel>=6.0.0
10
+ Requires-Dist: jsonapi-client>=0.9.9
11
+ Requires-Dist: jupyterlab>=4.0.0
12
+ Requires-Dist: marine-omics>=0.1.17
13
+ Requires-Dist: matplotlib-venn>=1.1.2
14
+ Requires-Dist: matplotlib>=3.8.0
15
+ Requires-Dist: numpy>=1.25.0
16
+ Requires-Dist: pandas>=2.0.0
17
+ Requires-Dist: pydantic>=2.12.0
18
+ Requires-Dist: pydeseq2>=0.5.4
19
+ Requires-Dist: requests>=2.31.0
20
+ Requires-Dist: scikit-learn>=1.4.0
21
+ Requires-Dist: scipy>=1.11.0
22
+ Requires-Dist: seaborn>=0.13.0
23
+ Requires-Dist: setuptools<81.0.0,>=68.0.0
24
+ Requires-Dist: tqdm>=4.66.0
25
+ Provides-Extra: dev
26
+ Requires-Dist: ipykernel>=6.0.0; extra == 'dev'
27
+ Requires-Dist: jupyterlab>=4.0.0; extra == 'dev'
28
+ Requires-Dist: mypy>=1.8.0; extra == 'dev'
29
+ Requires-Dist: pytest-cov>=4.1.0; extra == 'dev'
30
+ Requires-Dist: pytest>=8.0.0; extra == 'dev'
31
+ Requires-Dist: ruff>=0.1.0; extra == 'dev'
32
+ Provides-Extra: docs
33
+ Requires-Dist: myst-parser>=2.0.0; extra == 'docs'
34
+ Requires-Dist: sphinx-autodoc-typehints>=1.25.0; extra == 'docs'
35
+ Requires-Dist: sphinx-rtd-theme>=2.0.0; extra == 'docs'
36
+ Requires-Dist: sphinx>=7.0.0; extra == 'docs'
37
+ Description-Content-Type: text/markdown
38
+
39
+ # mgnify-methods
40
+
41
+ Support methods and classes for the Biodiversity studies on Mgnify metagenomes
42
+
43
+ ## Installation
44
+
45
+ ### Using uv (recommended)
46
+
47
+ ```bash
48
+ uv add mgnify-methods
49
+ ```
50
+
51
+ ### Using pip
52
+
53
+ ```bash
54
+ pip install mgnify-methods
55
+ ```
56
+
57
+ ### From source
58
+
59
+ ```bash
60
+ git clone https://github.com/palec87/mgnify-methods.git
61
+ cd mgnify-methods
62
+ uv sync
63
+ ```
64
+
65
+ ## Development
66
+
67
+ This project uses `uv` for dependency management and has a `Makefile` for common development tasks.
68
+
69
+ ### Setup development environment
70
+
71
+ ```bash
72
+ make dev-install
73
+ ```
74
+
75
+ ### Run tests
76
+
77
+ ```bash
78
+ make test
79
+ ```
80
+
81
+ ### Run linters
82
+
83
+ ```bash
84
+ make lint
85
+ ```
86
+
87
+ ### Format code
88
+
89
+ ```bash
90
+ make format
91
+ ```
92
+
93
+ ### Build documentation
94
+
95
+ ```bash
96
+ make docs
97
+ ```
98
+
99
+ ### Build package
100
+
101
+ ```bash
102
+ make build
103
+ ```
104
+
105
+ ### Available Make targets
106
+
107
+ Run `make help` to see all available targets.
108
+
109
+ ## Documentation
110
+
111
+ Documentation is available at [ReadTheDocs](https://mgnify-methods.readthedocs.io/) (once deployed).
112
+
113
+ ## License
114
+
115
+ See [LICENSE](LICENSE) file for details.
116
+
@@ -0,0 +1,78 @@
1
+ # mgnify-methods
2
+
3
+ Support methods and classes for the Biodiversity studies on Mgnify metagenomes
4
+
5
+ ## Installation
6
+
7
+ ### Using uv (recommended)
8
+
9
+ ```bash
10
+ uv add mgnify-methods
11
+ ```
12
+
13
+ ### Using pip
14
+
15
+ ```bash
16
+ pip install mgnify-methods
17
+ ```
18
+
19
+ ### From source
20
+
21
+ ```bash
22
+ git clone https://github.com/palec87/mgnify-methods.git
23
+ cd mgnify-methods
24
+ uv sync
25
+ ```
26
+
27
+ ## Development
28
+
29
+ This project uses `uv` for dependency management and has a `Makefile` for common development tasks.
30
+
31
+ ### Setup development environment
32
+
33
+ ```bash
34
+ make dev-install
35
+ ```
36
+
37
+ ### Run tests
38
+
39
+ ```bash
40
+ make test
41
+ ```
42
+
43
+ ### Run linters
44
+
45
+ ```bash
46
+ make lint
47
+ ```
48
+
49
+ ### Format code
50
+
51
+ ```bash
52
+ make format
53
+ ```
54
+
55
+ ### Build documentation
56
+
57
+ ```bash
58
+ make docs
59
+ ```
60
+
61
+ ### Build package
62
+
63
+ ```bash
64
+ make build
65
+ ```
66
+
67
+ ### Available Make targets
68
+
69
+ Run `make help` to see all available targets.
70
+
71
+ ## Documentation
72
+
73
+ Documentation is available at [ReadTheDocs](https://mgnify-methods.readthedocs.io/) (once deployed).
74
+
75
+ ## License
76
+
77
+ See [LICENSE](LICENSE) file for details.
78
+