de-quack 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.
- de_quack-0.1.0/LICENSE +21 -0
- de_quack-0.1.0/PKG-INFO +110 -0
- de_quack-0.1.0/README.md +80 -0
- de_quack-0.1.0/pyproject.toml +46 -0
- de_quack-0.1.0/setup.cfg +4 -0
- de_quack-0.1.0/src/de_quack.egg-info/PKG-INFO +110 -0
- de_quack-0.1.0/src/de_quack.egg-info/SOURCES.txt +8 -0
- de_quack-0.1.0/src/de_quack.egg-info/dependency_links.txt +1 -0
- de_quack-0.1.0/src/de_quack.egg-info/requires.txt +8 -0
- de_quack-0.1.0/src/de_quack.egg-info/top_level.txt +1 -0
de_quack-0.1.0/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Ziyang Xing
|
|
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.
|
de_quack-0.1.0/PKG-INFO
ADDED
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: de_quack
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Python library for differential expression data storage and visualization using DuckDB.
|
|
5
|
+
Author: yangp7833-commits
|
|
6
|
+
License: MIT
|
|
7
|
+
Keywords: duckdb,differential expression,bioinformatics,visualization,data management
|
|
8
|
+
Classifier: Programming Language :: Python :: 3
|
|
9
|
+
Classifier: Programming Language :: Python :: 3.8
|
|
10
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
11
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
12
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
14
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
15
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
16
|
+
Classifier: Operating System :: OS Independent
|
|
17
|
+
Classifier: Intended Audience :: Science/Research
|
|
18
|
+
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
|
|
19
|
+
Requires-Python: >=3.9
|
|
20
|
+
Description-Content-Type: text/markdown
|
|
21
|
+
License-File: LICENSE
|
|
22
|
+
Requires-Dist: duckdb>=1.0
|
|
23
|
+
Requires-Dist: pandas>=1.0
|
|
24
|
+
Requires-Dist: numpy>=1.20
|
|
25
|
+
Requires-Dist: matplotlib>=3.0
|
|
26
|
+
Requires-Dist: adjustText>=0.7
|
|
27
|
+
Provides-Extra: excel
|
|
28
|
+
Requires-Dist: openpyxl>=3.0; extra == "excel"
|
|
29
|
+
Dynamic: license-file
|
|
30
|
+
|
|
31
|
+
# de_quack
|
|
32
|
+
|
|
33
|
+
Python/R library for differential expression (DE) data management and visualization using DuckDB.
|
|
34
|
+
|
|
35
|
+
Stores DE analysis results with automatic gene annotation, enabling reproducible and efficient querying of experimental data.
|
|
36
|
+
|
|
37
|
+
## Features
|
|
38
|
+
|
|
39
|
+
- **Efficient Storage**: DuckDB-backed persistence for gene expression results
|
|
40
|
+
- **Automatic Annotation**: Maps gene symbols and Ensembl IDs with canonical references
|
|
41
|
+
- **Flexible Querying**: Filter results using simple keyword arguments (e.g., `padj__lt=0.05`)
|
|
42
|
+
- **Multi-language Support**: Native Python and R interfaces
|
|
43
|
+
- **Visualization**: Built-in volcano plot generation with publication-ready styling
|
|
44
|
+
- **Data Normalization**: Handles variable column names and formats automatically
|
|
45
|
+
|
|
46
|
+
## Installation
|
|
47
|
+
|
|
48
|
+
```bash
|
|
49
|
+
pip install de_quack
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
For Excel export support (optional):
|
|
53
|
+
```bash
|
|
54
|
+
pip install de_quack[excel]
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
## Quick Start
|
|
58
|
+
|
|
59
|
+
### Python
|
|
60
|
+
|
|
61
|
+
```python
|
|
62
|
+
from de_quack import de_duckling, volcano_plot
|
|
63
|
+
|
|
64
|
+
with de_duckling('results.duckdb') as db:
|
|
65
|
+
db.initialize_gene_table('human')
|
|
66
|
+
db.insert_to_database('data.txt')
|
|
67
|
+
results = db.query('gene_results', padj__lt=0.05)
|
|
68
|
+
print(results)
|
|
69
|
+
|
|
70
|
+
# Generate volcano plot
|
|
71
|
+
volcano_plot(results, padj=0.05, log2fc=1, plot_file='volcano.png')
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
### R
|
|
75
|
+
|
|
76
|
+
```r
|
|
77
|
+
# Find and source the wrapper directly from the pip installation directory
|
|
78
|
+
py_pkg_path <- dirname(reticulate::import("de_quack")$`__file__`)
|
|
79
|
+
source(file.path(py_pkg_path, "wrapper.R"))
|
|
80
|
+
|
|
81
|
+
# Initialize
|
|
82
|
+
duck <- de_quack(db_path = "results.duckdb")
|
|
83
|
+
duck$connect()
|
|
84
|
+
duck$initialize_gene_table('human')
|
|
85
|
+
duck$insert_to_database('data.txt')
|
|
86
|
+
results <- duck$query('gene_results', padj__lt=0.05)
|
|
87
|
+
duck$volcano_plot(results, padj=0.05, log2fc=1, plot_file='volcano.png')
|
|
88
|
+
duck$close()
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
## Database Schema
|
|
92
|
+
|
|
93
|
+
### Tables
|
|
94
|
+
|
|
95
|
+
- **experimental_data**: Metadata about DE analysis experiments
|
|
96
|
+
- **gene_results**: Individual gene-level results with statistics
|
|
97
|
+
- **genes**: Reference gene annotations (human, etc.)
|
|
98
|
+
|
|
99
|
+
### Advanced Querying & JSON Fallback
|
|
100
|
+
DeDuck supports intuitive field modifiers (`__lt`, `__gt`, `__lte`, `__gte`, `__ne`). If a metric isn't a native column in the database, DeDuck automatically queries it out of custom nested JSON metadata dynamically:
|
|
101
|
+
|
|
102
|
+
```python
|
|
103
|
+
# Regular column filtering + automatic nested JSON key metadata extraction
|
|
104
|
+
with de_duckling as db:
|
|
105
|
+
results = db.query('gene_results', padj__lt=0.05, custom_biotype__ne='pseudogene')
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
## License
|
|
109
|
+
|
|
110
|
+
MIT
|
de_quack-0.1.0/README.md
ADDED
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
# de_quack
|
|
2
|
+
|
|
3
|
+
Python/R library for differential expression (DE) data management and visualization using DuckDB.
|
|
4
|
+
|
|
5
|
+
Stores DE analysis results with automatic gene annotation, enabling reproducible and efficient querying of experimental data.
|
|
6
|
+
|
|
7
|
+
## Features
|
|
8
|
+
|
|
9
|
+
- **Efficient Storage**: DuckDB-backed persistence for gene expression results
|
|
10
|
+
- **Automatic Annotation**: Maps gene symbols and Ensembl IDs with canonical references
|
|
11
|
+
- **Flexible Querying**: Filter results using simple keyword arguments (e.g., `padj__lt=0.05`)
|
|
12
|
+
- **Multi-language Support**: Native Python and R interfaces
|
|
13
|
+
- **Visualization**: Built-in volcano plot generation with publication-ready styling
|
|
14
|
+
- **Data Normalization**: Handles variable column names and formats automatically
|
|
15
|
+
|
|
16
|
+
## Installation
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
pip install de_quack
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
For Excel export support (optional):
|
|
23
|
+
```bash
|
|
24
|
+
pip install de_quack[excel]
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Quick Start
|
|
28
|
+
|
|
29
|
+
### Python
|
|
30
|
+
|
|
31
|
+
```python
|
|
32
|
+
from de_quack import de_duckling, volcano_plot
|
|
33
|
+
|
|
34
|
+
with de_duckling('results.duckdb') as db:
|
|
35
|
+
db.initialize_gene_table('human')
|
|
36
|
+
db.insert_to_database('data.txt')
|
|
37
|
+
results = db.query('gene_results', padj__lt=0.05)
|
|
38
|
+
print(results)
|
|
39
|
+
|
|
40
|
+
# Generate volcano plot
|
|
41
|
+
volcano_plot(results, padj=0.05, log2fc=1, plot_file='volcano.png')
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
### R
|
|
45
|
+
|
|
46
|
+
```r
|
|
47
|
+
# Find and source the wrapper directly from the pip installation directory
|
|
48
|
+
py_pkg_path <- dirname(reticulate::import("de_quack")$`__file__`)
|
|
49
|
+
source(file.path(py_pkg_path, "wrapper.R"))
|
|
50
|
+
|
|
51
|
+
# Initialize
|
|
52
|
+
duck <- de_quack(db_path = "results.duckdb")
|
|
53
|
+
duck$connect()
|
|
54
|
+
duck$initialize_gene_table('human')
|
|
55
|
+
duck$insert_to_database('data.txt')
|
|
56
|
+
results <- duck$query('gene_results', padj__lt=0.05)
|
|
57
|
+
duck$volcano_plot(results, padj=0.05, log2fc=1, plot_file='volcano.png')
|
|
58
|
+
duck$close()
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
## Database Schema
|
|
62
|
+
|
|
63
|
+
### Tables
|
|
64
|
+
|
|
65
|
+
- **experimental_data**: Metadata about DE analysis experiments
|
|
66
|
+
- **gene_results**: Individual gene-level results with statistics
|
|
67
|
+
- **genes**: Reference gene annotations (human, etc.)
|
|
68
|
+
|
|
69
|
+
### Advanced Querying & JSON Fallback
|
|
70
|
+
DeDuck supports intuitive field modifiers (`__lt`, `__gt`, `__lte`, `__gte`, `__ne`). If a metric isn't a native column in the database, DeDuck automatically queries it out of custom nested JSON metadata dynamically:
|
|
71
|
+
|
|
72
|
+
```python
|
|
73
|
+
# Regular column filtering + automatic nested JSON key metadata extraction
|
|
74
|
+
with de_duckling as db:
|
|
75
|
+
results = db.query('gene_results', padj__lt=0.05, custom_biotype__ne='pseudogene')
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
## License
|
|
79
|
+
|
|
80
|
+
MIT
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools>=61.0", "wheel"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "de_quack"
|
|
7
|
+
version = "0.1.0"
|
|
8
|
+
description = "Python library for differential expression data storage and visualization using DuckDB."
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
requires-python = ">=3.9"
|
|
11
|
+
license = { text = "MIT" }
|
|
12
|
+
keywords = ["duckdb", "differential expression", "bioinformatics", "visualization", "data management"]
|
|
13
|
+
authors = [
|
|
14
|
+
{ name = "yangp7833-commits" }
|
|
15
|
+
]
|
|
16
|
+
classifiers = [
|
|
17
|
+
"Programming Language :: Python :: 3",
|
|
18
|
+
"Programming Language :: Python :: 3.8",
|
|
19
|
+
"Programming Language :: Python :: 3.9",
|
|
20
|
+
"Programming Language :: Python :: 3.10",
|
|
21
|
+
"Programming Language :: Python :: 3.11",
|
|
22
|
+
"Programming Language :: Python :: 3.12",
|
|
23
|
+
"Programming Language :: Python :: 3.13",
|
|
24
|
+
"License :: OSI Approved :: MIT License",
|
|
25
|
+
"Operating System :: OS Independent",
|
|
26
|
+
"Intended Audience :: Science/Research",
|
|
27
|
+
"Topic :: Scientific/Engineering :: Bio-Informatics"
|
|
28
|
+
]
|
|
29
|
+
|
|
30
|
+
dependencies = [
|
|
31
|
+
"duckdb>=1.0",
|
|
32
|
+
"pandas>=1.0",
|
|
33
|
+
"numpy>=1.20",
|
|
34
|
+
"matplotlib>=3.0",
|
|
35
|
+
"adjustText>=0.7"
|
|
36
|
+
]
|
|
37
|
+
|
|
38
|
+
[project.optional-dependencies]
|
|
39
|
+
excel = ["openpyxl>=3.0"]
|
|
40
|
+
|
|
41
|
+
[tool.setuptools.packages.find]
|
|
42
|
+
where = ["src"]
|
|
43
|
+
include = ["de_duck*"]
|
|
44
|
+
|
|
45
|
+
[tool.setuptools.package-data]
|
|
46
|
+
"*" = ["*.py"]
|
de_quack-0.1.0/setup.cfg
ADDED
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: de_quack
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Python library for differential expression data storage and visualization using DuckDB.
|
|
5
|
+
Author: yangp7833-commits
|
|
6
|
+
License: MIT
|
|
7
|
+
Keywords: duckdb,differential expression,bioinformatics,visualization,data management
|
|
8
|
+
Classifier: Programming Language :: Python :: 3
|
|
9
|
+
Classifier: Programming Language :: Python :: 3.8
|
|
10
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
11
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
12
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
13
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
14
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
15
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
16
|
+
Classifier: Operating System :: OS Independent
|
|
17
|
+
Classifier: Intended Audience :: Science/Research
|
|
18
|
+
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
|
|
19
|
+
Requires-Python: >=3.9
|
|
20
|
+
Description-Content-Type: text/markdown
|
|
21
|
+
License-File: LICENSE
|
|
22
|
+
Requires-Dist: duckdb>=1.0
|
|
23
|
+
Requires-Dist: pandas>=1.0
|
|
24
|
+
Requires-Dist: numpy>=1.20
|
|
25
|
+
Requires-Dist: matplotlib>=3.0
|
|
26
|
+
Requires-Dist: adjustText>=0.7
|
|
27
|
+
Provides-Extra: excel
|
|
28
|
+
Requires-Dist: openpyxl>=3.0; extra == "excel"
|
|
29
|
+
Dynamic: license-file
|
|
30
|
+
|
|
31
|
+
# de_quack
|
|
32
|
+
|
|
33
|
+
Python/R library for differential expression (DE) data management and visualization using DuckDB.
|
|
34
|
+
|
|
35
|
+
Stores DE analysis results with automatic gene annotation, enabling reproducible and efficient querying of experimental data.
|
|
36
|
+
|
|
37
|
+
## Features
|
|
38
|
+
|
|
39
|
+
- **Efficient Storage**: DuckDB-backed persistence for gene expression results
|
|
40
|
+
- **Automatic Annotation**: Maps gene symbols and Ensembl IDs with canonical references
|
|
41
|
+
- **Flexible Querying**: Filter results using simple keyword arguments (e.g., `padj__lt=0.05`)
|
|
42
|
+
- **Multi-language Support**: Native Python and R interfaces
|
|
43
|
+
- **Visualization**: Built-in volcano plot generation with publication-ready styling
|
|
44
|
+
- **Data Normalization**: Handles variable column names and formats automatically
|
|
45
|
+
|
|
46
|
+
## Installation
|
|
47
|
+
|
|
48
|
+
```bash
|
|
49
|
+
pip install de_quack
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
For Excel export support (optional):
|
|
53
|
+
```bash
|
|
54
|
+
pip install de_quack[excel]
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
## Quick Start
|
|
58
|
+
|
|
59
|
+
### Python
|
|
60
|
+
|
|
61
|
+
```python
|
|
62
|
+
from de_quack import de_duckling, volcano_plot
|
|
63
|
+
|
|
64
|
+
with de_duckling('results.duckdb') as db:
|
|
65
|
+
db.initialize_gene_table('human')
|
|
66
|
+
db.insert_to_database('data.txt')
|
|
67
|
+
results = db.query('gene_results', padj__lt=0.05)
|
|
68
|
+
print(results)
|
|
69
|
+
|
|
70
|
+
# Generate volcano plot
|
|
71
|
+
volcano_plot(results, padj=0.05, log2fc=1, plot_file='volcano.png')
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
### R
|
|
75
|
+
|
|
76
|
+
```r
|
|
77
|
+
# Find and source the wrapper directly from the pip installation directory
|
|
78
|
+
py_pkg_path <- dirname(reticulate::import("de_quack")$`__file__`)
|
|
79
|
+
source(file.path(py_pkg_path, "wrapper.R"))
|
|
80
|
+
|
|
81
|
+
# Initialize
|
|
82
|
+
duck <- de_quack(db_path = "results.duckdb")
|
|
83
|
+
duck$connect()
|
|
84
|
+
duck$initialize_gene_table('human')
|
|
85
|
+
duck$insert_to_database('data.txt')
|
|
86
|
+
results <- duck$query('gene_results', padj__lt=0.05)
|
|
87
|
+
duck$volcano_plot(results, padj=0.05, log2fc=1, plot_file='volcano.png')
|
|
88
|
+
duck$close()
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
## Database Schema
|
|
92
|
+
|
|
93
|
+
### Tables
|
|
94
|
+
|
|
95
|
+
- **experimental_data**: Metadata about DE analysis experiments
|
|
96
|
+
- **gene_results**: Individual gene-level results with statistics
|
|
97
|
+
- **genes**: Reference gene annotations (human, etc.)
|
|
98
|
+
|
|
99
|
+
### Advanced Querying & JSON Fallback
|
|
100
|
+
DeDuck supports intuitive field modifiers (`__lt`, `__gt`, `__lte`, `__gte`, `__ne`). If a metric isn't a native column in the database, DeDuck automatically queries it out of custom nested JSON metadata dynamically:
|
|
101
|
+
|
|
102
|
+
```python
|
|
103
|
+
# Regular column filtering + automatic nested JSON key metadata extraction
|
|
104
|
+
with de_duckling as db:
|
|
105
|
+
results = db.query('gene_results', padj__lt=0.05, custom_biotype__ne='pseudogene')
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
## License
|
|
109
|
+
|
|
110
|
+
MIT
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|