pylocuszoom 0.2.0__tar.gz → 0.3.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.
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/CHANGELOG.md +29 -2
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/PKG-INFO +28 -14
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/README.md +26 -10
- pylocuszoom-0.3.0/bioconda/meta.yaml +54 -0
- pylocuszoom-0.3.0/examples/eqtl_overlay.png +0 -0
- pylocuszoom-0.3.0/examples/finemapping_plot.png +0 -0
- pylocuszoom-0.3.0/examples/getting_started.ipynb +1007 -0
- pylocuszoom-0.3.0/examples/regional_plot.png +0 -0
- pylocuszoom-0.3.0/examples/stacked_plot.png +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/pyproject.toml +7 -5
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/backends/base.py +2 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/backends/bokeh_backend.py +220 -48
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/backends/matplotlib_backend.py +29 -7
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/backends/plotly_backend.py +262 -20
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/finemapping.py +0 -1
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/gene_track.py +231 -23
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/plotter.py +277 -139
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/tests/test_finemapping.py +0 -1
- pylocuszoom-0.3.0/tests/test_notebook_backends.py +457 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/tests/test_plotter.py +145 -1
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/uv.lock +238 -7
- pylocuszoom-0.2.0/examples/eqtl_overlay.png +0 -0
- pylocuszoom-0.2.0/examples/finemapping_plot.png +0 -0
- pylocuszoom-0.2.0/examples/getting_started.ipynb +0 -240
- pylocuszoom-0.2.0/examples/regional_plot.png +0 -0
- pylocuszoom-0.2.0/examples/stacked_plot.png +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/.github/workflows/ci.yml +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/.github/workflows/publish.yml +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/.gitignore +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/CONTRIBUTING.md +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/LICENSE.md +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/docs/ARCHITECTURE.md +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/examples/generate_readme_plots.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/logo.svg +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/__init__.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/backends/__init__.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/colors.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/eqtl.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/labels.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/ld.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/logging.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/recombination.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/reference_data/__init__.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/src/pylocuszoom/utils.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/tests/conftest.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/tests/test_colors.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/tests/test_gene_track.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/tests/test_labels.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/tests/test_ld.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/tests/test_logging.py +0 -0
- {pylocuszoom-0.2.0 → pylocuszoom-0.3.0}/tests/test_recombination.py +0 -0
|
@@ -5,7 +5,33 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
-
## [
|
|
8
|
+
## [0.3.0] - 2026-01-26
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
- Bioconda recipe for conda installation
|
|
12
|
+
- `adjustText` moved to default dependencies (was optional)
|
|
13
|
+
- **Interactive plotly backend** - use `backend="plotly"` for hover tooltips and pan/zoom
|
|
14
|
+
- **Interactive bokeh backend** - use `backend="bokeh"` for dashboard-ready plots
|
|
15
|
+
|
|
16
|
+
### Changed
|
|
17
|
+
- `plot()` and `plot_stacked()` now use backend protocol for all rendering (scatter, line, axes, layout)
|
|
18
|
+
- **Gene track now works with all backends** (plotly, bokeh, matplotlib)
|
|
19
|
+
- **Recombination overlay now works with all backends** - secondary y-axis with rate line and fill
|
|
20
|
+
- **LD legend now works with all backends** - r² color scale (lead SNP highlighted in plot, not legend)
|
|
21
|
+
- SNP labels remain matplotlib-only (interactive backends use hover tooltips instead)
|
|
22
|
+
- Default `genomewide_threshold` changed from 5e-7 to 5e-8 (standard GWAS significance)
|
|
23
|
+
- Gene track strand colors: forward strand now goldenrod (#DAA520), reverse strand light blue (#6BB3FF)
|
|
24
|
+
- Gene track directional arrows: black for forward, dark grey for reverse
|
|
25
|
+
- Added panel spacing (hspace=0.1) between stacked/fine-mapping panels for visual separation
|
|
26
|
+
- Tightened gene track internal spacing for more compact layout
|
|
27
|
+
|
|
28
|
+
### Fixed
|
|
29
|
+
- Bokeh backend `x_range=None` error when creating figures with shared x-axis
|
|
30
|
+
- Bokeh backend `legend_label=None` error in scatter plots
|
|
31
|
+
- Bokeh backend LD legend not rendering (empty scatter plots don't create legend glyphs)
|
|
32
|
+
- Bokeh backend deprecated `FuncTickFormatter` replaced with `CustomJSTickFormatter`
|
|
33
|
+
- Bokeh backend deprecated `circle()` method replaced with `scatter(marker=...)`
|
|
34
|
+
- Bokeh backend `FIXED_SIZING_MODE` validation warning in column layouts
|
|
9
35
|
|
|
10
36
|
## [0.2.0] - 2026-01-26
|
|
11
37
|
|
|
@@ -54,6 +80,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
54
80
|
- bokeh >= 3.8.2
|
|
55
81
|
- kaleido >= 0.2.0
|
|
56
82
|
|
|
57
|
-
[Unreleased]: https://github.com/michael-denyer/pyLocusZoom/compare/v0.
|
|
83
|
+
[Unreleased]: https://github.com/michael-denyer/pyLocusZoom/compare/v0.3.0...HEAD
|
|
84
|
+
[0.3.0]: https://github.com/michael-denyer/pyLocusZoom/compare/v0.2.0...v0.3.0
|
|
58
85
|
[0.2.0]: https://github.com/michael-denyer/pyLocusZoom/compare/v0.1.0...v0.2.0
|
|
59
86
|
[0.1.0]: https://github.com/michael-denyer/pyLocusZoom/releases/tag/v0.1.0
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pylocuszoom
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.3.0
|
|
4
4
|
Summary: Regional association plots for GWAS results with LD coloring, gene tracks, and recombination rate overlays
|
|
5
5
|
Project-URL: Homepage, https://github.com/michael-denyer/pylocuszoom
|
|
6
6
|
Project-URL: Documentation, https://github.com/michael-denyer/pylocuszoom#readme
|
|
@@ -19,6 +19,7 @@ Classifier: Programming Language :: Python :: 3.12
|
|
|
19
19
|
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
|
|
20
20
|
Classifier: Topic :: Scientific/Engineering :: Visualization
|
|
21
21
|
Requires-Python: >=3.10
|
|
22
|
+
Requires-Dist: adjusttext>=0.8
|
|
22
23
|
Requires-Dist: bokeh>=3.8.2
|
|
23
24
|
Requires-Dist: kaleido>=0.2.0
|
|
24
25
|
Requires-Dist: loguru>=0.7.0
|
|
@@ -28,14 +29,11 @@ Requires-Dist: pandas>=1.4.0
|
|
|
28
29
|
Requires-Dist: plotly>=5.0.0
|
|
29
30
|
Requires-Dist: pyliftover>=0.4
|
|
30
31
|
Provides-Extra: all
|
|
31
|
-
Requires-Dist: adjusttext>=0.8; extra == 'all'
|
|
32
32
|
Requires-Dist: pyspark>=3.0.0; extra == 'all'
|
|
33
33
|
Provides-Extra: dev
|
|
34
34
|
Requires-Dist: pytest-cov>=4.0.0; extra == 'dev'
|
|
35
35
|
Requires-Dist: pytest>=7.0.0; extra == 'dev'
|
|
36
36
|
Requires-Dist: ruff>=0.1.0; extra == 'dev'
|
|
37
|
-
Provides-Extra: labels
|
|
38
|
-
Requires-Dist: adjusttext>=0.8; extra == 'labels'
|
|
39
37
|
Provides-Extra: spark
|
|
40
38
|
Requires-Dist: pyspark>=3.0.0; extra == 'spark'
|
|
41
39
|
Description-Content-Type: text/markdown
|
|
@@ -75,14 +73,20 @@ Inspired by [LocusZoom](http://locuszoom.org/) and [locuszoomr](https://github.c
|
|
|
75
73
|
|
|
76
74
|
## Installation
|
|
77
75
|
|
|
76
|
+
```bash
|
|
77
|
+
pip install pylocuszoom
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
Or with uv:
|
|
81
|
+
|
|
78
82
|
```bash
|
|
79
83
|
uv add pylocuszoom
|
|
80
84
|
```
|
|
81
85
|
|
|
82
|
-
Or with
|
|
86
|
+
Or with conda (Bioconda):
|
|
83
87
|
|
|
84
88
|
```bash
|
|
85
|
-
|
|
89
|
+
conda install -c bioconda pylocuszoom
|
|
86
90
|
```
|
|
87
91
|
|
|
88
92
|
## Quick Start
|
|
@@ -165,20 +169,30 @@ fig = plotter.plot(
|
|
|
165
169
|
)
|
|
166
170
|
```
|
|
167
171
|
|
|
168
|
-
##
|
|
172
|
+
## Backends
|
|
169
173
|
|
|
170
|
-
|
|
174
|
+
pyLocusZoom supports multiple rendering backends:
|
|
171
175
|
|
|
172
176
|
```python
|
|
173
|
-
# Static publication-quality plot (default
|
|
174
|
-
|
|
175
|
-
fig = plotter.plot(gwas_df, chrom=1, start=1000000, end=2000000)
|
|
177
|
+
# Static publication-quality plot (default)
|
|
178
|
+
fig = plotter.plot(gwas_df, chrom=1, start=1000000, end=2000000, backend="matplotlib")
|
|
176
179
|
fig.savefig("plot.png", dpi=150)
|
|
180
|
+
|
|
181
|
+
# Interactive Plotly (hover tooltips, pan/zoom)
|
|
182
|
+
fig = plotter.plot(gwas_df, chrom=1, start=1000000, end=2000000, backend="plotly")
|
|
183
|
+
fig.write_html("plot.html")
|
|
184
|
+
|
|
185
|
+
# Interactive Bokeh (dashboard-ready)
|
|
186
|
+
fig = plotter.plot(gwas_df, chrom=1, start=1000000, end=2000000, backend="bokeh")
|
|
177
187
|
```
|
|
178
188
|
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
189
|
+
| Backend | Output | Best For |
|
|
190
|
+
|---------|--------|----------|
|
|
191
|
+
| `matplotlib` | Static PNG/PDF/SVG | Publications, presentations |
|
|
192
|
+
| `plotly` | Interactive HTML | Web reports, data exploration |
|
|
193
|
+
| `bokeh` | Interactive HTML | Dashboards, web apps |
|
|
194
|
+
|
|
195
|
+
> **Note:** All backends support gene track, recombination overlay, and LD legend. SNP labels (auto-positioned with adjustText) are matplotlib-only.
|
|
182
196
|
|
|
183
197
|
## Stacked Plots
|
|
184
198
|
|
|
@@ -33,14 +33,20 @@ Inspired by [LocusZoom](http://locuszoom.org/) and [locuszoomr](https://github.c
|
|
|
33
33
|
|
|
34
34
|
## Installation
|
|
35
35
|
|
|
36
|
+
```bash
|
|
37
|
+
pip install pylocuszoom
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
Or with uv:
|
|
41
|
+
|
|
36
42
|
```bash
|
|
37
43
|
uv add pylocuszoom
|
|
38
44
|
```
|
|
39
45
|
|
|
40
|
-
Or with
|
|
46
|
+
Or with conda (Bioconda):
|
|
41
47
|
|
|
42
48
|
```bash
|
|
43
|
-
|
|
49
|
+
conda install -c bioconda pylocuszoom
|
|
44
50
|
```
|
|
45
51
|
|
|
46
52
|
## Quick Start
|
|
@@ -123,20 +129,30 @@ fig = plotter.plot(
|
|
|
123
129
|
)
|
|
124
130
|
```
|
|
125
131
|
|
|
126
|
-
##
|
|
132
|
+
## Backends
|
|
127
133
|
|
|
128
|
-
|
|
134
|
+
pyLocusZoom supports multiple rendering backends:
|
|
129
135
|
|
|
130
136
|
```python
|
|
131
|
-
# Static publication-quality plot (default
|
|
132
|
-
|
|
133
|
-
fig = plotter.plot(gwas_df, chrom=1, start=1000000, end=2000000)
|
|
137
|
+
# Static publication-quality plot (default)
|
|
138
|
+
fig = plotter.plot(gwas_df, chrom=1, start=1000000, end=2000000, backend="matplotlib")
|
|
134
139
|
fig.savefig("plot.png", dpi=150)
|
|
140
|
+
|
|
141
|
+
# Interactive Plotly (hover tooltips, pan/zoom)
|
|
142
|
+
fig = plotter.plot(gwas_df, chrom=1, start=1000000, end=2000000, backend="plotly")
|
|
143
|
+
fig.write_html("plot.html")
|
|
144
|
+
|
|
145
|
+
# Interactive Bokeh (dashboard-ready)
|
|
146
|
+
fig = plotter.plot(gwas_df, chrom=1, start=1000000, end=2000000, backend="bokeh")
|
|
135
147
|
```
|
|
136
148
|
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
149
|
+
| Backend | Output | Best For |
|
|
150
|
+
|---------|--------|----------|
|
|
151
|
+
| `matplotlib` | Static PNG/PDF/SVG | Publications, presentations |
|
|
152
|
+
| `plotly` | Interactive HTML | Web reports, data exploration |
|
|
153
|
+
| `bokeh` | Interactive HTML | Dashboards, web apps |
|
|
154
|
+
|
|
155
|
+
> **Note:** All backends support gene track, recombination overlay, and LD legend. SNP labels (auto-positioned with adjustText) are matplotlib-only.
|
|
140
156
|
|
|
141
157
|
## Stacked Plots
|
|
142
158
|
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
{% set name = "pylocuszoom" %}
|
|
2
|
+
{% set version = "0.3.0" %}
|
|
3
|
+
|
|
4
|
+
package:
|
|
5
|
+
name: {{ name|lower }}
|
|
6
|
+
version: {{ version }}
|
|
7
|
+
|
|
8
|
+
source:
|
|
9
|
+
url: https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/{{ name }}-{{ version }}.tar.gz
|
|
10
|
+
sha256: REPLACE_WITH_SHA256_AFTER_PYPI_PUBLISH
|
|
11
|
+
|
|
12
|
+
build:
|
|
13
|
+
noarch: python
|
|
14
|
+
number: 0
|
|
15
|
+
script: {{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation
|
|
16
|
+
|
|
17
|
+
requirements:
|
|
18
|
+
host:
|
|
19
|
+
- python >=3.10
|
|
20
|
+
- pip
|
|
21
|
+
- hatchling
|
|
22
|
+
run:
|
|
23
|
+
- python >=3.10
|
|
24
|
+
- matplotlib-base >=3.5.0
|
|
25
|
+
- pandas >=1.4.0
|
|
26
|
+
- numpy >=1.21.0
|
|
27
|
+
- loguru >=0.7.0
|
|
28
|
+
- pyliftover >=0.4
|
|
29
|
+
- plotly >=5.0.0
|
|
30
|
+
- bokeh >=3.8.2
|
|
31
|
+
- python-kaleido >=0.2.0
|
|
32
|
+
- adjusttext >=0.8
|
|
33
|
+
|
|
34
|
+
test:
|
|
35
|
+
imports:
|
|
36
|
+
- pylocuszoom
|
|
37
|
+
commands:
|
|
38
|
+
- python -c "from pylocuszoom import LocusZoomPlotter"
|
|
39
|
+
|
|
40
|
+
about:
|
|
41
|
+
home: https://github.com/michael-denyer/pylocuszoom
|
|
42
|
+
license: GPL-3.0-or-later
|
|
43
|
+
license_family: GPL3
|
|
44
|
+
license_file: LICENSE
|
|
45
|
+
summary: Regional association plots for GWAS results with LD coloring
|
|
46
|
+
description: |
|
|
47
|
+
pyLocusZoom creates publication-quality regional association plots
|
|
48
|
+
for GWAS results with LD coloring, gene tracks, and recombination
|
|
49
|
+
rate overlays. Supports canine, feline, and custom species.
|
|
50
|
+
dev_url: https://github.com/michael-denyer/pylocuszoom
|
|
51
|
+
|
|
52
|
+
extra:
|
|
53
|
+
recipe-maintainers:
|
|
54
|
+
- michael-denyer
|
|
Binary file
|
|
Binary file
|