genoabo 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.
- genoabo-0.1.0/.gitignore +33 -0
- genoabo-0.1.0/LICENSE +21 -0
- genoabo-0.1.0/PKG-INFO +153 -0
- genoabo-0.1.0/README.md +116 -0
- genoabo-0.1.0/genoabo/data/__init__.py +0 -0
- genoabo-0.1.0/genoabo/data/alleles.yaml +33 -0
- genoabo-0.1.0/genoabo/data/assemblies.yaml +78 -0
- genoabo-0.1.0/genoabo/data/citations.yaml +136 -0
- genoabo-0.1.0/genoabo/data/markers.yaml +105 -0
- genoabo-0.1.0/genoabo/data/methods.yaml +74 -0
- genoabo-0.1.0/genoabo/data/report.yaml +151 -0
- genoabo-0.1.0/pyproject.toml +76 -0
genoabo-0.1.0/.gitignore
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Python
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*.egg-info/
|
|
5
|
+
.eggs/
|
|
6
|
+
dist/
|
|
7
|
+
build/
|
|
8
|
+
.pytest_cache/
|
|
9
|
+
.mypy_cache/
|
|
10
|
+
.ruff_cache/
|
|
11
|
+
.coverage
|
|
12
|
+
htmlcov/
|
|
13
|
+
*.egg
|
|
14
|
+
|
|
15
|
+
# Local / IDE
|
|
16
|
+
.venv/
|
|
17
|
+
venv/
|
|
18
|
+
.env
|
|
19
|
+
.idea/
|
|
20
|
+
.vscode/
|
|
21
|
+
.DS_Store
|
|
22
|
+
|
|
23
|
+
# pytest temp dirs
|
|
24
|
+
pytest-cache-files-*/
|
|
25
|
+
|
|
26
|
+
# Local derivation downloads (UCSC chain, CHM13 dbSNP VCF)
|
|
27
|
+
/data/
|
|
28
|
+
|
|
29
|
+
# Example run outputs
|
|
30
|
+
examples/out/
|
|
31
|
+
|
|
32
|
+
# Zensical site build
|
|
33
|
+
site/
|
genoabo-0.1.0/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Yunye He
|
|
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.
|
genoabo-0.1.0/PKG-INFO
ADDED
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: genoabo
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Genetically determined ABO blood group inference from genotype datasets
|
|
5
|
+
Project-URL: Homepage, https://github.com/cloufield/genoABO
|
|
6
|
+
Project-URL: Repository, https://github.com/cloufield/genoABO
|
|
7
|
+
Author: Yunye He
|
|
8
|
+
License-Expression: MIT
|
|
9
|
+
License-File: LICENSE
|
|
10
|
+
Keywords: ABO,GWAS,biobank,bioinformatics,blood-group,genotype
|
|
11
|
+
Classifier: Development Status :: 4 - Beta
|
|
12
|
+
Classifier: Intended Audience :: Science/Research
|
|
13
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
14
|
+
Classifier: Programming Language :: Python :: 3
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
17
|
+
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
|
|
18
|
+
Requires-Python: >=3.11
|
|
19
|
+
Requires-Dist: bgen-reader>=4.0
|
|
20
|
+
Requires-Dist: cyvcf2>=0.30
|
|
21
|
+
Requires-Dist: numpy>=1.24
|
|
22
|
+
Requires-Dist: pgenlib>=0.94
|
|
23
|
+
Requires-Dist: pyyaml>=6.0
|
|
24
|
+
Requires-Dist: rich>=13.0
|
|
25
|
+
Requires-Dist: typer>=0.9
|
|
26
|
+
Provides-Extra: bgenix
|
|
27
|
+
Requires-Dist: bgenix>=1.1; extra == 'bgenix'
|
|
28
|
+
Provides-Extra: dev
|
|
29
|
+
Requires-Dist: mypy>=1.5; extra == 'dev'
|
|
30
|
+
Requires-Dist: pytest-cov>=4.1; extra == 'dev'
|
|
31
|
+
Requires-Dist: pytest>=7.4; extra == 'dev'
|
|
32
|
+
Requires-Dist: ruff>=0.1; extra == 'dev'
|
|
33
|
+
Requires-Dist: types-pyyaml>=6.0; extra == 'dev'
|
|
34
|
+
Provides-Extra: docs
|
|
35
|
+
Requires-Dist: zensical; extra == 'docs'
|
|
36
|
+
Description-Content-Type: text/markdown
|
|
37
|
+
|
|
38
|
+
# genoABO
|
|
39
|
+
|
|
40
|
+
**genoABO** infers genetically determined ABO blood group from VCF, BGEN, PGEN, and PLINK genotype datasets.
|
|
41
|
+
|
|
42
|
+
```bash
|
|
43
|
+
pip install genoabo
|
|
44
|
+
genoabo biobank.pgen --out bloodgroup
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
> **Research use only.** genoABO is intended for population-genetics, epidemiology, GWAS, PheWAS, and biobank research. Genotype-inferred ABO groups do not capture all rare, weak, cis-AB, structural, or otherwise atypical ABO alleles and **must not** be used for transfusion or clinical decision-making.
|
|
48
|
+
|
|
49
|
+
## Quick start
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
genoabo cohort.pgen --out abo
|
|
53
|
+
# writes: abo.abo.tsv, abo.qc.tsv, abo.summary.txt, abo.report.html
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
See [docs/workflow.md](docs/workflow.md) for the full load-to-output pipeline.
|
|
57
|
+
|
|
58
|
+
See [examples/](examples/) for VCF (unphased and phased), PGEN, and PLINK1 demos across builds and marker notations, a 1000 Genomes EAS four-marker example (phased `--phase auto`, or forced unphased), and a multi-ancestry `--assume-bo` check against phased 1KG AFR/AMR/EAS/EUR.
|
|
59
|
+
|
|
60
|
+
Inspect markers without calling:
|
|
61
|
+
|
|
62
|
+
```bash
|
|
63
|
+
genoabo cohort.pgen --inspect
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
## Supported formats
|
|
67
|
+
|
|
68
|
+
| Format | Extensions | Notes |
|
|
69
|
+
|--------|------------|-------|
|
|
70
|
+
| VCF/BCF | `.vcf`, `.vcf.gz`, `.bcf` | GT, phased GT, DS, GP |
|
|
71
|
+
| PLINK2 | `.pgen` + `.pvar` + `.psam` | Auto-locates companion files |
|
|
72
|
+
| PLINK1 | `.bed` + `.bim` + `.fam` | `--format plink1` |
|
|
73
|
+
| BGEN | `.bgen` + `.sample` | Dosage/probability support |
|
|
74
|
+
|
|
75
|
+
## Methods
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
genoabo --methods
|
|
79
|
+
genoabo --method-info three-marker
|
|
80
|
+
genoabo data.pgen --method auto # default
|
|
81
|
+
genoabo data.pgen --method common
|
|
82
|
+
genoabo data.pgen --method three-marker
|
|
83
|
+
genoabo data.pgen --method ukb
|
|
84
|
+
genoabo data.pgen --method extended
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
| Method | Markers | Use case |
|
|
88
|
+
|--------|---------|----------|
|
|
89
|
+
| `common` | rs8176719, rs8176746 | Standard 2-marker inference |
|
|
90
|
+
| `three-marker` | + rs8176747 | East Asian / extra B check |
|
|
91
|
+
| `ukb` | rs8176719, rs8176746, rs505922 | UK Biobank Field 23165 style |
|
|
92
|
+
| `extended` | ISBT YAML (v0.1: A.01, B.01, O.01) | Experimental allele matching |
|
|
93
|
+
|
|
94
|
+
## Options
|
|
95
|
+
|
|
96
|
+
```text
|
|
97
|
+
--format auto|vcf|bcf|bgen|pgen|plink1
|
|
98
|
+
--build auto|hg19|hg38|chm13
|
|
99
|
+
--geno-mode auto|hardcall|dosage|probability
|
|
100
|
+
--phase auto|phased|unphased
|
|
101
|
+
--assume-bo / --no-assume-bo
|
|
102
|
+
--min-genotype-prob 0.90
|
|
103
|
+
--dosage-hardcall-threshold 0.1
|
|
104
|
+
--strict-method
|
|
105
|
+
--inspect
|
|
106
|
+
--report PATH.html
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
## Python API
|
|
110
|
+
|
|
111
|
+
```python
|
|
112
|
+
from genoabo import ABOCaller
|
|
113
|
+
|
|
114
|
+
caller = ABOCaller(method="auto", build="auto")
|
|
115
|
+
result = caller.call("ukb.pgen")
|
|
116
|
+
for call in result.calls:
|
|
117
|
+
print(call.sample.iid, call.abo_group, call.abo_genotype)
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
## Genome builds
|
|
121
|
+
|
|
122
|
+
GRCh37/hg19, GRCh38/hg38, and T2T-CHM13v2 are supported. Build auto-detection uses marker coordinates, VCF header metadata, and chromosome lengths. Conflicting evidence returns an error requiring explicit `--build`.
|
|
123
|
+
|
|
124
|
+
## Citations
|
|
125
|
+
|
|
126
|
+
Full records are printed by `genoabo --method-info NAME` and in the Citations section of each HTML run report.
|
|
127
|
+
|
|
128
|
+
- **software** — Yunye He. genoABO: genetically determined ABO blood group inference from genotype datasets. Version 0.1.0. 2026. [https://github.com/cloufield/genoABO](https://github.com/cloufield/genoABO).
|
|
129
|
+
- **common** — Melzer D, Perry JRB, Hernandez D, Corsi AM, Stevens K, Rafferty I, et al. A genome-wide association study identifies protein quantitative trait loci (pQTLs). *PLoS Genet*. 2008;4:e1000072. [DOI: 10.1371/journal.pgen.1000072](https://doi.org/10.1371/journal.pgen.1000072). PMID: [18464913](https://pubmed.ncbi.nlm.nih.gov/18464913/).
|
|
130
|
+
- **three-marker** — Fry AE, Griffiths MJ, Auburn S, Diakite M, Forton JT, Green A, et al. Common variation in the ABO glycosyltransferase is associated with susceptibility to severe *Plasmodium falciparum* malaria. *Hum Mol Genet*. 2008;17:567–576. [DOI: 10.1093/hmg/ddm331](https://doi.org/10.1093/hmg/ddm331). PMID: [18003641](https://pubmed.ncbi.nlm.nih.gov/18003641/).
|
|
131
|
+
- **ukb** — UK Biobank. Data-Field 23165: Blood-type haplotype. [https://biobank.ndph.ox.ac.uk/showcase/field.cgi?id=23165](https://biobank.ndph.ox.ac.uk/showcase/field.cgi?id=23165).
|
|
132
|
+
- **extended** — Daniels GL, Fletcher A, Garratty G, Henry S, Jørgensen J, Judd WJ, et al. Blood group terminology 2004: from the International Society of Blood Transfusion committee on terminology for red cell surface antigens. *Vox Sang*. 2004;87:304–316. [DOI: 10.1111/j.1423-0410.2004.00564.x](https://doi.org/10.1111/j.1423-0410.2004.00564.x). PMID: [15585029](https://pubmed.ncbi.nlm.nih.gov/15585029/).
|
|
133
|
+
|
|
134
|
+
See [Inference methods](docs/methods.md) for used-in and molecular-basis notes.
|
|
135
|
+
|
|
136
|
+
## Documentation
|
|
137
|
+
|
|
138
|
+
Preview the docs site locally:
|
|
139
|
+
|
|
140
|
+
```bash
|
|
141
|
+
pip install -e ".[docs]"
|
|
142
|
+
./serve.sh # http://127.0.0.1:8000
|
|
143
|
+
zensical build # writes ./site/
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
- [Inference methods](docs/methods.md)
|
|
147
|
+
- [Marker coordinates](docs/markers.md)
|
|
148
|
+
- [Assumptions and limitations](docs/assumptions.md)
|
|
149
|
+
- [Examples](examples/)
|
|
150
|
+
|
|
151
|
+
## License
|
|
152
|
+
|
|
153
|
+
MIT — see [LICENSE](LICENSE).
|
genoabo-0.1.0/README.md
ADDED
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
# genoABO
|
|
2
|
+
|
|
3
|
+
**genoABO** infers genetically determined ABO blood group from VCF, BGEN, PGEN, and PLINK genotype datasets.
|
|
4
|
+
|
|
5
|
+
```bash
|
|
6
|
+
pip install genoabo
|
|
7
|
+
genoabo biobank.pgen --out bloodgroup
|
|
8
|
+
```
|
|
9
|
+
|
|
10
|
+
> **Research use only.** genoABO is intended for population-genetics, epidemiology, GWAS, PheWAS, and biobank research. Genotype-inferred ABO groups do not capture all rare, weak, cis-AB, structural, or otherwise atypical ABO alleles and **must not** be used for transfusion or clinical decision-making.
|
|
11
|
+
|
|
12
|
+
## Quick start
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
genoabo cohort.pgen --out abo
|
|
16
|
+
# writes: abo.abo.tsv, abo.qc.tsv, abo.summary.txt, abo.report.html
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
See [docs/workflow.md](docs/workflow.md) for the full load-to-output pipeline.
|
|
20
|
+
|
|
21
|
+
See [examples/](examples/) for VCF (unphased and phased), PGEN, and PLINK1 demos across builds and marker notations, a 1000 Genomes EAS four-marker example (phased `--phase auto`, or forced unphased), and a multi-ancestry `--assume-bo` check against phased 1KG AFR/AMR/EAS/EUR.
|
|
22
|
+
|
|
23
|
+
Inspect markers without calling:
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
genoabo cohort.pgen --inspect
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
## Supported formats
|
|
30
|
+
|
|
31
|
+
| Format | Extensions | Notes |
|
|
32
|
+
|--------|------------|-------|
|
|
33
|
+
| VCF/BCF | `.vcf`, `.vcf.gz`, `.bcf` | GT, phased GT, DS, GP |
|
|
34
|
+
| PLINK2 | `.pgen` + `.pvar` + `.psam` | Auto-locates companion files |
|
|
35
|
+
| PLINK1 | `.bed` + `.bim` + `.fam` | `--format plink1` |
|
|
36
|
+
| BGEN | `.bgen` + `.sample` | Dosage/probability support |
|
|
37
|
+
|
|
38
|
+
## Methods
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
genoabo --methods
|
|
42
|
+
genoabo --method-info three-marker
|
|
43
|
+
genoabo data.pgen --method auto # default
|
|
44
|
+
genoabo data.pgen --method common
|
|
45
|
+
genoabo data.pgen --method three-marker
|
|
46
|
+
genoabo data.pgen --method ukb
|
|
47
|
+
genoabo data.pgen --method extended
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
| Method | Markers | Use case |
|
|
51
|
+
|--------|---------|----------|
|
|
52
|
+
| `common` | rs8176719, rs8176746 | Standard 2-marker inference |
|
|
53
|
+
| `three-marker` | + rs8176747 | East Asian / extra B check |
|
|
54
|
+
| `ukb` | rs8176719, rs8176746, rs505922 | UK Biobank Field 23165 style |
|
|
55
|
+
| `extended` | ISBT YAML (v0.1: A.01, B.01, O.01) | Experimental allele matching |
|
|
56
|
+
|
|
57
|
+
## Options
|
|
58
|
+
|
|
59
|
+
```text
|
|
60
|
+
--format auto|vcf|bcf|bgen|pgen|plink1
|
|
61
|
+
--build auto|hg19|hg38|chm13
|
|
62
|
+
--geno-mode auto|hardcall|dosage|probability
|
|
63
|
+
--phase auto|phased|unphased
|
|
64
|
+
--assume-bo / --no-assume-bo
|
|
65
|
+
--min-genotype-prob 0.90
|
|
66
|
+
--dosage-hardcall-threshold 0.1
|
|
67
|
+
--strict-method
|
|
68
|
+
--inspect
|
|
69
|
+
--report PATH.html
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
## Python API
|
|
73
|
+
|
|
74
|
+
```python
|
|
75
|
+
from genoabo import ABOCaller
|
|
76
|
+
|
|
77
|
+
caller = ABOCaller(method="auto", build="auto")
|
|
78
|
+
result = caller.call("ukb.pgen")
|
|
79
|
+
for call in result.calls:
|
|
80
|
+
print(call.sample.iid, call.abo_group, call.abo_genotype)
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
## Genome builds
|
|
84
|
+
|
|
85
|
+
GRCh37/hg19, GRCh38/hg38, and T2T-CHM13v2 are supported. Build auto-detection uses marker coordinates, VCF header metadata, and chromosome lengths. Conflicting evidence returns an error requiring explicit `--build`.
|
|
86
|
+
|
|
87
|
+
## Citations
|
|
88
|
+
|
|
89
|
+
Full records are printed by `genoabo --method-info NAME` and in the Citations section of each HTML run report.
|
|
90
|
+
|
|
91
|
+
- **software** — Yunye He. genoABO: genetically determined ABO blood group inference from genotype datasets. Version 0.1.0. 2026. [https://github.com/cloufield/genoABO](https://github.com/cloufield/genoABO).
|
|
92
|
+
- **common** — Melzer D, Perry JRB, Hernandez D, Corsi AM, Stevens K, Rafferty I, et al. A genome-wide association study identifies protein quantitative trait loci (pQTLs). *PLoS Genet*. 2008;4:e1000072. [DOI: 10.1371/journal.pgen.1000072](https://doi.org/10.1371/journal.pgen.1000072). PMID: [18464913](https://pubmed.ncbi.nlm.nih.gov/18464913/).
|
|
93
|
+
- **three-marker** — Fry AE, Griffiths MJ, Auburn S, Diakite M, Forton JT, Green A, et al. Common variation in the ABO glycosyltransferase is associated with susceptibility to severe *Plasmodium falciparum* malaria. *Hum Mol Genet*. 2008;17:567–576. [DOI: 10.1093/hmg/ddm331](https://doi.org/10.1093/hmg/ddm331). PMID: [18003641](https://pubmed.ncbi.nlm.nih.gov/18003641/).
|
|
94
|
+
- **ukb** — UK Biobank. Data-Field 23165: Blood-type haplotype. [https://biobank.ndph.ox.ac.uk/showcase/field.cgi?id=23165](https://biobank.ndph.ox.ac.uk/showcase/field.cgi?id=23165).
|
|
95
|
+
- **extended** — Daniels GL, Fletcher A, Garratty G, Henry S, Jørgensen J, Judd WJ, et al. Blood group terminology 2004: from the International Society of Blood Transfusion committee on terminology for red cell surface antigens. *Vox Sang*. 2004;87:304–316. [DOI: 10.1111/j.1423-0410.2004.00564.x](https://doi.org/10.1111/j.1423-0410.2004.00564.x). PMID: [15585029](https://pubmed.ncbi.nlm.nih.gov/15585029/).
|
|
96
|
+
|
|
97
|
+
See [Inference methods](docs/methods.md) for used-in and molecular-basis notes.
|
|
98
|
+
|
|
99
|
+
## Documentation
|
|
100
|
+
|
|
101
|
+
Preview the docs site locally:
|
|
102
|
+
|
|
103
|
+
```bash
|
|
104
|
+
pip install -e ".[docs]"
|
|
105
|
+
./serve.sh # http://127.0.0.1:8000
|
|
106
|
+
zensical build # writes ./site/
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
- [Inference methods](docs/methods.md)
|
|
110
|
+
- [Marker coordinates](docs/markers.md)
|
|
111
|
+
- [Assumptions and limitations](docs/assumptions.md)
|
|
112
|
+
- [Examples](examples/)
|
|
113
|
+
|
|
114
|
+
## License
|
|
115
|
+
|
|
116
|
+
MIT — see [LICENSE](LICENSE).
|
|
File without changes
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Extended method allele definitions — v0.1 minimal set only.
|
|
2
|
+
# ISBT nomenclature; not clinical blood typing.
|
|
3
|
+
|
|
4
|
+
isbt_database:
|
|
5
|
+
name: "ISBT Blood Group Database / BGMUT"
|
|
6
|
+
url: "https://www.isbtweb.org/blood-group-terminology/"
|
|
7
|
+
version_note: "Record version at release; nomenclature evolves"
|
|
8
|
+
|
|
9
|
+
alleles:
|
|
10
|
+
ABO*O.01:
|
|
11
|
+
phenotype: O
|
|
12
|
+
description: "Common O allele (261delG)"
|
|
13
|
+
variants:
|
|
14
|
+
rs8176719: O_DEL
|
|
15
|
+
haplotype_state: O
|
|
16
|
+
|
|
17
|
+
ABO*B.01:
|
|
18
|
+
phenotype: B
|
|
19
|
+
description: "Common B allele"
|
|
20
|
+
variants:
|
|
21
|
+
rs8176719: NON_O
|
|
22
|
+
rs8176746: B_ALLELE
|
|
23
|
+
rs8176747: B_ALLELE
|
|
24
|
+
haplotype_state: B
|
|
25
|
+
|
|
26
|
+
ABO*A.01:
|
|
27
|
+
phenotype: A
|
|
28
|
+
description: "Common A allele"
|
|
29
|
+
variants:
|
|
30
|
+
rs8176719: NON_O
|
|
31
|
+
rs8176746: A_ALLELE
|
|
32
|
+
rs8176747: A_ALLELE
|
|
33
|
+
haplotype_state: A
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
# Assembly registry — all coordinates must cite a source.
|
|
2
|
+
# CHM13v2 packaged positions are UCSC hg38-chm13v2.over.chain.gz liftOver from GRCh38.
|
|
3
|
+
# scripts/derive_chm13_markers.py is an optional alternative (dbSNP VCF scan).
|
|
4
|
+
|
|
5
|
+
GRCh37:
|
|
6
|
+
aliases: [hg19, GRCh37.p13]
|
|
7
|
+
chr9_length: 141213431
|
|
8
|
+
chr9_source: "NCBI NC_000009.11"
|
|
9
|
+
contigs:
|
|
10
|
+
"9":
|
|
11
|
+
aliases: [chr9, NC_000009.11]
|
|
12
|
+
markers:
|
|
13
|
+
rs8176719:
|
|
14
|
+
chrom: "9"
|
|
15
|
+
pos: 136132908
|
|
16
|
+
source: "dbSNP rs8176719 NC_000009.11"
|
|
17
|
+
rs8176746:
|
|
18
|
+
chrom: "9"
|
|
19
|
+
pos: 136131322
|
|
20
|
+
source: "dbSNP rs8176746 NC_000009.11"
|
|
21
|
+
rs8176747:
|
|
22
|
+
chrom: "9"
|
|
23
|
+
pos: 136131315
|
|
24
|
+
source: "dbSNP rs8176747 NC_000009.11"
|
|
25
|
+
rs505922:
|
|
26
|
+
chrom: "9"
|
|
27
|
+
pos: 136149229
|
|
28
|
+
source: "dbSNP rs505922 NC_000009.11"
|
|
29
|
+
|
|
30
|
+
GRCh38:
|
|
31
|
+
aliases: [hg38, GRCh38.p14]
|
|
32
|
+
chr9_length: 138394717
|
|
33
|
+
chr9_source: "NCBI NC_000009.12"
|
|
34
|
+
contigs:
|
|
35
|
+
"9":
|
|
36
|
+
aliases: [chr9, NC_000009.12]
|
|
37
|
+
markers:
|
|
38
|
+
rs8176719:
|
|
39
|
+
chrom: "9"
|
|
40
|
+
pos: 133257521
|
|
41
|
+
source: "dbSNP rs8176719 NC_000009.12"
|
|
42
|
+
rs8176746:
|
|
43
|
+
chrom: "9"
|
|
44
|
+
pos: 133255935
|
|
45
|
+
source: "dbSNP rs8176746 NC_000009.12"
|
|
46
|
+
rs8176747:
|
|
47
|
+
chrom: "9"
|
|
48
|
+
pos: 133255928
|
|
49
|
+
source: "dbSNP rs8176747 NC_000009.12"
|
|
50
|
+
rs505922:
|
|
51
|
+
chrom: "9"
|
|
52
|
+
pos: 133273813
|
|
53
|
+
source: "dbSNP rs505922 NC_000009.12"
|
|
54
|
+
|
|
55
|
+
CHM13v2:
|
|
56
|
+
aliases: [chm13, T2T-CHM13v2, hs1]
|
|
57
|
+
chr9_length: 150617247
|
|
58
|
+
chr9_source: "T2T-CHM13v2.0 NC_060925.1"
|
|
59
|
+
contigs:
|
|
60
|
+
"9":
|
|
61
|
+
aliases: [chr9, NC_060925.1]
|
|
62
|
+
markers:
|
|
63
|
+
rs8176719:
|
|
64
|
+
chrom: "9"
|
|
65
|
+
pos: 145471385
|
|
66
|
+
source: "UCSC hg38-chm13v2.over.chain.gz liftOver from GRCh38:133257521"
|
|
67
|
+
rs8176746:
|
|
68
|
+
chrom: "9"
|
|
69
|
+
pos: 145469798
|
|
70
|
+
source: "UCSC hg38-chm13v2.over.chain.gz liftOver from GRCh38:133255935"
|
|
71
|
+
rs8176747:
|
|
72
|
+
chrom: "9"
|
|
73
|
+
pos: 145469791
|
|
74
|
+
source: "UCSC hg38-chm13v2.over.chain.gz liftOver from GRCh38:133255928"
|
|
75
|
+
rs505922:
|
|
76
|
+
chrom: "9"
|
|
77
|
+
pos: 145487688
|
|
78
|
+
source: "UCSC hg38-chm13v2.over.chain.gz liftOver from GRCh38:133273813"
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
software:
|
|
2
|
+
title: "genoABO: genetically determined ABO blood group inference from genotype datasets"
|
|
3
|
+
authors: "Yunye He"
|
|
4
|
+
year: 2026
|
|
5
|
+
version: "0.1.0"
|
|
6
|
+
url: "https://github.com/cloufield/genoABO"
|
|
7
|
+
license: MIT
|
|
8
|
+
|
|
9
|
+
# role: primary = first description of this typing scheme (or operational spec)
|
|
10
|
+
# used_in = later application that used the same markers
|
|
11
|
+
# molecular = molecular allele definitions, not a SNP typing paper
|
|
12
|
+
methods:
|
|
13
|
+
common:
|
|
14
|
+
description: "Common 2-marker inference using rs8176719 and rs8176746"
|
|
15
|
+
references:
|
|
16
|
+
- role: primary
|
|
17
|
+
doi: "10.1371/journal.pgen.1000072"
|
|
18
|
+
pmid: "18464913"
|
|
19
|
+
title: "A genome-wide association study identifies protein quantitative trait loci (pQTLs)"
|
|
20
|
+
authors: "Melzer D, Perry JRB, Hernandez D, Corsi AM, Stevens K, Rafferty I, et al."
|
|
21
|
+
journal: "PLoS Genet"
|
|
22
|
+
year: 2008
|
|
23
|
+
volume: "4"
|
|
24
|
+
pages: "e1000072"
|
|
25
|
+
note: "Recoded ABO from a two-SNP haplotype of rs8176746 and rs8176719"
|
|
26
|
+
- role: used_in
|
|
27
|
+
doi: "10.1161/ATVBAHA.119.313658"
|
|
28
|
+
pmid: "31969017"
|
|
29
|
+
title: "Genetically Determined ABO Blood Group and its Associations With Health and Disease"
|
|
30
|
+
authors: "Groot HE, Villegas Sierra LE, Said MA, Lipsic E, Karper JC, van der Harst P"
|
|
31
|
+
journal: "Arterioscler Thromb Vasc Biol"
|
|
32
|
+
year: 2020
|
|
33
|
+
volume: "40"
|
|
34
|
+
pages: "830-838"
|
|
35
|
+
note: "UK Biobank (n=406,755); inferred ABO from rs8176719 and rs8176746"
|
|
36
|
+
|
|
37
|
+
three-marker:
|
|
38
|
+
description: "3-marker inference using rs8176719, rs8176746, and rs8176747"
|
|
39
|
+
references:
|
|
40
|
+
- role: primary
|
|
41
|
+
doi: "10.1093/hmg/ddm331"
|
|
42
|
+
pmid: "18003641"
|
|
43
|
+
title: "Common variation in the ABO glycosyltransferase is associated with susceptibility to severe Plasmodium falciparum malaria"
|
|
44
|
+
authors: "Fry AE, Griffiths MJ, Auburn S, Diakite M, Forton JT, Green A, et al."
|
|
45
|
+
journal: "Hum Mol Genet"
|
|
46
|
+
year: 2008
|
|
47
|
+
volume: "17"
|
|
48
|
+
pages: "567-576"
|
|
49
|
+
note: "Designed large-scale assays for rs8176719, rs8176746, and rs8176747 (plus rs8176743)"
|
|
50
|
+
- role: used_in
|
|
51
|
+
doi: "10.1111/j.1349-7006.2011.01907.x"
|
|
52
|
+
pmid: "21306478"
|
|
53
|
+
title: "ABO blood group alleles and the risk of pancreatic cancer in a Japanese population"
|
|
54
|
+
authors: "Nakao M, Matsuo K, Hosono S, Ogata S, Ito H, Watanabe M, et al."
|
|
55
|
+
journal: "Cancer Sci"
|
|
56
|
+
year: 2011
|
|
57
|
+
volume: "102"
|
|
58
|
+
pages: "1076-1080"
|
|
59
|
+
- role: used_in
|
|
60
|
+
doi: "10.1038/s41588-021-00931-x"
|
|
61
|
+
pmid: "34594039"
|
|
62
|
+
title: "A cross-population atlas of genetic associations for 220 human phenotypes"
|
|
63
|
+
authors: "Sakaue S, Kanai M, Tanigawa Y, et al."
|
|
64
|
+
journal: "Nat Genet"
|
|
65
|
+
year: 2021
|
|
66
|
+
volume: "53"
|
|
67
|
+
pages: "1415-1424"
|
|
68
|
+
note: "BBJ, UKB, and FinnGen (ntotal ≈ 628,000); estimated ABO from rs8176747, rs8176746, and rs8176719 (preprint 2020)"
|
|
69
|
+
- role: used_in
|
|
70
|
+
doi: "10.1002/ajh.26307"
|
|
71
|
+
pmid: "34329492"
|
|
72
|
+
title: "Characterization of the human ABO genotypes and their association to common inflammatory and cardiovascular diseases in the UK Biobank"
|
|
73
|
+
authors: "Höglund J, Karlsson T, Johansson T, Ek WE, Johansson Å"
|
|
74
|
+
journal: "Am J Hematol"
|
|
75
|
+
year: 2021
|
|
76
|
+
volume: "96"
|
|
77
|
+
pages: "1350-1362"
|
|
78
|
+
note: "UK Biobank; inferred ABO genotypes from rs8176719, rs8176746, and rs8176747"
|
|
79
|
+
|
|
80
|
+
ukb:
|
|
81
|
+
description: "UK Biobank Field 23165 blood-type haplotype inference"
|
|
82
|
+
references:
|
|
83
|
+
- role: primary
|
|
84
|
+
url: "https://biobank.ndph.ox.ac.uk/showcase/field.cgi?id=23165"
|
|
85
|
+
title: "UK Biobank Data-Field 23165: Blood-type haplotype"
|
|
86
|
+
authors: "UK Biobank"
|
|
87
|
+
year: 2020
|
|
88
|
+
note: "Operational specification: rs8176719 deletion = O; rs505922 T as O proxy when rs8176719 is missing; rs8176746 T = B"
|
|
89
|
+
- role: used_in
|
|
90
|
+
doi: "10.1371/journal.pgen.1000072"
|
|
91
|
+
pmid: "18464913"
|
|
92
|
+
title: "A genome-wide association study identifies protein quantitative trait loci (pQTLs)"
|
|
93
|
+
authors: "Melzer D, Perry JRB, Hernandez D, Corsi AM, Stevens K, Rafferty I, et al."
|
|
94
|
+
journal: "PLoS Genet"
|
|
95
|
+
year: 2008
|
|
96
|
+
volume: "4"
|
|
97
|
+
pages: "e1000072"
|
|
98
|
+
note: "Cited by Field 23165; two-SNP ABO recoding and rs505922"
|
|
99
|
+
- role: used_in
|
|
100
|
+
doi: "10.1371/journal.pgen.1000118"
|
|
101
|
+
pmid: "18604267"
|
|
102
|
+
title: "Novel association of ABO histo-blood group antigen with soluble ICAM-1: results of a genome-wide association study of 6,578 women"
|
|
103
|
+
authors: "Paré G, Chasman DI, Kellogg M, Zee RYL, Rifai N, Badola S, Miletich JP, Ridker PM"
|
|
104
|
+
journal: "PLoS Genet"
|
|
105
|
+
year: 2008
|
|
106
|
+
volume: "4"
|
|
107
|
+
pages: "e1000118"
|
|
108
|
+
note: "Cited by Field 23165"
|
|
109
|
+
|
|
110
|
+
extended:
|
|
111
|
+
description: "ISBT allele nomenclature reference (v0.1 limited subset)"
|
|
112
|
+
references:
|
|
113
|
+
- role: primary
|
|
114
|
+
doi: "10.1111/j.1423-0410.2004.00564.x"
|
|
115
|
+
pmid: "15585029"
|
|
116
|
+
title: "Blood group terminology 2004: from the International Society of Blood Transfusion committee on terminology for red cell surface antigens"
|
|
117
|
+
authors: "Daniels GL, Fletcher A, Garratty G, Henry S, Jørgensen J, Judd WJ, et al."
|
|
118
|
+
journal: "Vox Sang"
|
|
119
|
+
year: 2004
|
|
120
|
+
volume: "87"
|
|
121
|
+
pages: "304-316"
|
|
122
|
+
- role: primary
|
|
123
|
+
url: "https://blooddatabase.isbtweb.org/"
|
|
124
|
+
title: "ISBT Blood Group Database"
|
|
125
|
+
authors: "International Society of Blood Transfusion Working Party on Red Cell Immunogenetics and Blood Group Terminology"
|
|
126
|
+
note: "Authoritative allele tables; nomenclature evolves. Accessed 2026-09"
|
|
127
|
+
- role: molecular
|
|
128
|
+
doi: "10.1038/345229a0"
|
|
129
|
+
pmid: "2333095"
|
|
130
|
+
title: "Molecular genetic basis of the histo-blood group ABO system"
|
|
131
|
+
authors: "Yamamoto F, Clausen H, White T, Marken J, Hakomori S"
|
|
132
|
+
journal: "Nature"
|
|
133
|
+
year: 1990
|
|
134
|
+
volume: "345"
|
|
135
|
+
pages: "229-233"
|
|
136
|
+
note: "Molecular definitions underlying ABO*A.01, ABO*B.01, and ABO*O.01"
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
# Biological marker definitions — independent of VCF REF/ALT orientation.
|
|
2
|
+
# See docs/markers.md for coordinate provenance.
|
|
3
|
+
|
|
4
|
+
rs8176719:
|
|
5
|
+
role: O_defining
|
|
6
|
+
transcript: "NM_020469.4:c.261delG"
|
|
7
|
+
description: "Major common O-defining loss-of-function (261delG)"
|
|
8
|
+
states:
|
|
9
|
+
O_DEL:
|
|
10
|
+
description: "261G deleted — functional O allele (ABO*O.01 background)"
|
|
11
|
+
copies: 0
|
|
12
|
+
NON_O:
|
|
13
|
+
description: "261G present — A or B functional background"
|
|
14
|
+
copies: 1
|
|
15
|
+
# Common VCF representations on GRCh37/38 (O = reference, A/B = insC)
|
|
16
|
+
representations:
|
|
17
|
+
- note: "GRCh38 O reference — insertion alt"
|
|
18
|
+
ref: "G"
|
|
19
|
+
alt: ["GC"]
|
|
20
|
+
state: NON_O
|
|
21
|
+
- note: "GRCh38 O reference — no alt (homozygous O)"
|
|
22
|
+
ref: "G"
|
|
23
|
+
alt: []
|
|
24
|
+
state: O_DEL
|
|
25
|
+
- note: "Legacy deletion notation"
|
|
26
|
+
ref: "G"
|
|
27
|
+
alt: ["G-"]
|
|
28
|
+
state: O_DEL
|
|
29
|
+
- note: "Insertion on O-ref representing NON_O"
|
|
30
|
+
ref: "G"
|
|
31
|
+
alt: ["GinsC"]
|
|
32
|
+
state: NON_O
|
|
33
|
+
- note: "Left-aligned 1KG / normalized VCF (T:TC instead of G:GC)"
|
|
34
|
+
ref: "T"
|
|
35
|
+
alt: ["TC"]
|
|
36
|
+
state: NON_O
|
|
37
|
+
- note: "Left-aligned O reference (T, no alt)"
|
|
38
|
+
ref: "T"
|
|
39
|
+
alt: []
|
|
40
|
+
state: O_DEL
|
|
41
|
+
|
|
42
|
+
rs8176746:
|
|
43
|
+
role: AB_differentiating
|
|
44
|
+
transcript: "NM_020469.4:c.796C>A"
|
|
45
|
+
description: "Major A/B differentiating variant (796C>A, Leu266Met on B)"
|
|
46
|
+
states:
|
|
47
|
+
A_ALLELE:
|
|
48
|
+
description: "796C — A-associated"
|
|
49
|
+
B_ALLELE:
|
|
50
|
+
description: "796A — B-associated (VCF may show T on forward strand)"
|
|
51
|
+
representations:
|
|
52
|
+
- note: "Forward strand G ref, A alt"
|
|
53
|
+
ref: "G"
|
|
54
|
+
alt: ["A"]
|
|
55
|
+
state: B_ALLELE
|
|
56
|
+
- note: "Homozygous A background"
|
|
57
|
+
ref: "G"
|
|
58
|
+
alt: []
|
|
59
|
+
state: A_ALLELE
|
|
60
|
+
- note: "Alternate T notation (UKB field 23165)"
|
|
61
|
+
ref: "G"
|
|
62
|
+
alt: ["T"]
|
|
63
|
+
state: B_ALLELE
|
|
64
|
+
|
|
65
|
+
rs8176747:
|
|
66
|
+
role: AB_differentiating
|
|
67
|
+
transcript: "NM_020469.4:c.803G>C"
|
|
68
|
+
description: "Additional A/B differentiating variant (803G>C)"
|
|
69
|
+
states:
|
|
70
|
+
A_ALLELE:
|
|
71
|
+
description: "803G — A-associated"
|
|
72
|
+
B_ALLELE:
|
|
73
|
+
description: "803C — B-associated"
|
|
74
|
+
representations:
|
|
75
|
+
- note: "Forward strand G ref, C alt"
|
|
76
|
+
ref: "G"
|
|
77
|
+
alt: ["C"]
|
|
78
|
+
state: B_ALLELE
|
|
79
|
+
- note: "Homozygous A background"
|
|
80
|
+
ref: "G"
|
|
81
|
+
alt: []
|
|
82
|
+
state: A_ALLELE
|
|
83
|
+
- note: "GRCh38 / 1KG C ref, G alt"
|
|
84
|
+
ref: "C"
|
|
85
|
+
alt: ["G"]
|
|
86
|
+
state: B_ALLELE
|
|
87
|
+
|
|
88
|
+
rs505922:
|
|
89
|
+
role: O_proxy
|
|
90
|
+
transcript: null
|
|
91
|
+
description: "Proxy marker for O-related haplotype inference (LD with ABO O)"
|
|
92
|
+
states:
|
|
93
|
+
O_PROXY:
|
|
94
|
+
description: "T allele — proxy indicator for O haplotype (UKB fallback)"
|
|
95
|
+
NON_O_PROXY:
|
|
96
|
+
description: "C allele — not O proxy indicator"
|
|
97
|
+
representations:
|
|
98
|
+
- note: "Standard dbSNP"
|
|
99
|
+
ref: "C"
|
|
100
|
+
alt: ["T"]
|
|
101
|
+
state: O_PROXY
|
|
102
|
+
- note: "Homozygous non-O proxy"
|
|
103
|
+
ref: "C"
|
|
104
|
+
alt: []
|
|
105
|
+
state: NON_O_PROXY
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
methods:
|
|
2
|
+
common:
|
|
3
|
+
name: common
|
|
4
|
+
description: "Common 2-marker inference (rs8176719 + rs8176746)"
|
|
5
|
+
markers: [rs8176719, rs8176746]
|
|
6
|
+
outputs: [ABO_group, ABO_genotype]
|
|
7
|
+
min_markers: [rs8176719, rs8176746]
|
|
8
|
+
report:
|
|
9
|
+
logic:
|
|
10
|
+
- "Markers: rs8176719 (O deletion) and rs8176746 (A/B differentiator)."
|
|
11
|
+
- "If rs8176719 is O_DEL on a haplotype, that haplotype is O."
|
|
12
|
+
- "Otherwise rs8176746 B_ALLELE yields B and A_ALLELE yields A."
|
|
13
|
+
- "Infers the six common diplotypes A/A, A/O, B/B, B/O, A/B, and O/O when uniquely determined."
|
|
14
|
+
- "When both markers are heterozygous and unphased, --assume-bo (default) assigns B/O; --no-assume-bo leaves the call ambiguous (A/O or B/O)."
|
|
15
|
+
limitations:
|
|
16
|
+
- "Rare ABO alleles can violate the two-marker assumptions and may be misclassified."
|
|
17
|
+
- "The default --assume-bo rule (O deletion on an A background → B/O) is a common-allele assumption. Phased 1000 Genomes 30x hg38: AMR/EAS/EUR double-hets were all B/O; AFR 8/113 were A/O. Pass --no-assume-bo to leave those samples ambiguous."
|
|
18
|
+
|
|
19
|
+
three-marker:
|
|
20
|
+
name: three-marker
|
|
21
|
+
description: "3-marker inference (+ rs8176747); useful for East Asian datasets"
|
|
22
|
+
markers: [rs8176719, rs8176746, rs8176747]
|
|
23
|
+
outputs: [ABO_group, ABO_genotype]
|
|
24
|
+
min_markers: [rs8176719, rs8176746, rs8176747]
|
|
25
|
+
report:
|
|
26
|
+
logic:
|
|
27
|
+
- "Markers: rs8176719, rs8176746, and rs8176747 (additional A/B check)."
|
|
28
|
+
- "Haplotype rules match the common method, with rs8176747 confirming B vs A."
|
|
29
|
+
- "If rs8176746 and rs8176747 disagree on B vs A, a QC warning is raised and confidence is low."
|
|
30
|
+
limitations:
|
|
31
|
+
- "Marker disagreement between rs8176746 and rs8176747 is flagged, not resolved into a forced phenotype."
|
|
32
|
+
|
|
33
|
+
ukb:
|
|
34
|
+
name: ukb
|
|
35
|
+
description: "UK Biobank Field 23165 style (rs8176719, rs8176746, rs505922 proxy)"
|
|
36
|
+
markers: [rs8176719, rs8176746, rs505922]
|
|
37
|
+
outputs: [ABO_group, ABO_genotype, ukb_haplotype]
|
|
38
|
+
min_markers: [rs8176746]
|
|
39
|
+
proxy_markers: [rs505922]
|
|
40
|
+
report:
|
|
41
|
+
logic:
|
|
42
|
+
- "Implements UK Biobank Data-Field 23165 haplotype logic."
|
|
43
|
+
- "rs8176719 O_DEL indicates an O haplotype on that chromosome."
|
|
44
|
+
- "If rs8176719 is missing, rs505922 O_PROXY (T) is used as an O proxy and confidence is capped at low."
|
|
45
|
+
- "rs8176746 B_ALLELE indicates a B haplotype; otherwise a non-O haplotype is treated as A."
|
|
46
|
+
- "Output includes UKB-style haplotype codes: AA, AO, BO, BB, AB, OO."
|
|
47
|
+
limitations:
|
|
48
|
+
- "Proxy inference with rs505922 is not equivalent to typing the functional O deletion."
|
|
49
|
+
|
|
50
|
+
extended:
|
|
51
|
+
name: extended
|
|
52
|
+
description: "Curated ISBT allele definitions (v0.1: A.01, B.01, O.01 only)"
|
|
53
|
+
markers: [rs8176719, rs8176746, rs8176747]
|
|
54
|
+
outputs: [ABO_group, ABO_genotype, ISBT_alleles]
|
|
55
|
+
min_markers: [rs8176719]
|
|
56
|
+
report:
|
|
57
|
+
logic:
|
|
58
|
+
- "Match phased or resolved haplotypes against ISBT allele patterns in alleles.yaml."
|
|
59
|
+
- "v0.1 recognises ABO*A.01, ABO*B.01, and ABO*O.01 only."
|
|
60
|
+
- "If no pattern matches, ABO_group is unknown; classification is not forced."
|
|
61
|
+
limitations:
|
|
62
|
+
- "Not an ISBT-comprehensive typing method; unmatched alleles remain unknown."
|
|
63
|
+
|
|
64
|
+
auto_selection:
|
|
65
|
+
- method: three-marker
|
|
66
|
+
requires: [rs8176719, rs8176746, rs8176747]
|
|
67
|
+
reason: "rs8176719, rs8176746 and rs8176747 available"
|
|
68
|
+
- method: common
|
|
69
|
+
requires: [rs8176719, rs8176746]
|
|
70
|
+
reason: "rs8176719 and rs8176746 available"
|
|
71
|
+
- method: ukb
|
|
72
|
+
requires: [rs8176746, rs505922]
|
|
73
|
+
reason: "rs8176746 and rs505922 available (proxy mode)"
|
|
74
|
+
confidence_cap: low
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
disclaimer: >-
|
|
2
|
+
Research use only. Genotype-inferred ABO groups do not capture all rare, weak,
|
|
3
|
+
cis-AB, structural, or otherwise atypical ABO alleles and must not be used for
|
|
4
|
+
transfusion or clinical decision-making.
|
|
5
|
+
|
|
6
|
+
pipeline:
|
|
7
|
+
- >-
|
|
8
|
+
genoABO fetches only ABO tag SNPs (rs8176719, rs8176746, rs8176747, rs505922)
|
|
9
|
+
from the input file. Variants are matched by rsID, contig and position (including
|
|
10
|
+
chr-prefixed and RefSeq contig aliases), then by allele-aware keys.
|
|
11
|
+
- >-
|
|
12
|
+
Genome build is resolved from marker coordinates, file-header metadata, and
|
|
13
|
+
contig lengths, or taken from an explicit --build setting. Conflicting evidence
|
|
14
|
+
is an error; the build is never guessed silently.
|
|
15
|
+
- >-
|
|
16
|
+
Per-sample genotypes are interpreted from hardcalls (GT), dosage (DS), or
|
|
17
|
+
genotype probabilities (GP) according to the selected genotype mode. REF/ALT
|
|
18
|
+
alleles are then mapped to biological marker states. Inference rules never
|
|
19
|
+
operate on raw VCF alleles.
|
|
20
|
+
- >-
|
|
21
|
+
The selected method applies haplotype and diplotype rules and emits ABO_group,
|
|
22
|
+
ABO_genotype, confidence, and QC fields.
|
|
23
|
+
|
|
24
|
+
diplotype_phenotype:
|
|
25
|
+
- {diplotype: "A/A", phenotype: "A"}
|
|
26
|
+
- {diplotype: "A/O", phenotype: "A"}
|
|
27
|
+
- {diplotype: "B/B", phenotype: "B"}
|
|
28
|
+
- {diplotype: "B/O", phenotype: "B"}
|
|
29
|
+
- {diplotype: "A/B", phenotype: "AB"}
|
|
30
|
+
- {diplotype: "O/O", phenotype: "O"}
|
|
31
|
+
|
|
32
|
+
confidence:
|
|
33
|
+
- level: high
|
|
34
|
+
criteria: Direct functional markers; consistent genotypes; phase sufficient
|
|
35
|
+
- level: medium
|
|
36
|
+
criteria: Unphased but uniquely inferable
|
|
37
|
+
- level: low
|
|
38
|
+
criteria: Proxy marker, uncertain dosage, or unusual marker combinations
|
|
39
|
+
- level: none
|
|
40
|
+
criteria: Insufficient or conflicting evidence
|
|
41
|
+
|
|
42
|
+
confidence_note: Confidence is not a calibrated probability.
|
|
43
|
+
|
|
44
|
+
genotype_modes:
|
|
45
|
+
- mode: hardcall
|
|
46
|
+
behavior: Discrete GT (0/0, 0/1, 1/1, or phased)
|
|
47
|
+
- mode: dosage
|
|
48
|
+
behavior: Threshold ALT dosage into 0/1/2 copies; otherwise uncertain
|
|
49
|
+
- mode: probability
|
|
50
|
+
behavior: Argmax GP if max(P) meets the minimum probability threshold; otherwise uncertain
|
|
51
|
+
- mode: auto
|
|
52
|
+
behavior: GP, then DS, then hardcall GT, in that order of precedence
|
|
53
|
+
|
|
54
|
+
abo_group_meaning: >-
|
|
55
|
+
ABO_group is the inferred phenotype (A, B, AB, or O). unknown means the method
|
|
56
|
+
could not assign a group. ABO_genotype is the diplotype (for example A/O);
|
|
57
|
+
ambiguous means more than one diplotype was compatible with the unphased genotypes.
|
|
58
|
+
Population A/B/AB/O percentages are informational only; samples are never rejected
|
|
59
|
+
for frequency deviation.
|
|
60
|
+
|
|
61
|
+
abo_columns:
|
|
62
|
+
- {name: FID, description: "Family or cohort identifier from the input file"}
|
|
63
|
+
- {name: IID, description: "Individual sample identifier"}
|
|
64
|
+
- {name: ABO_group, description: "Inferred phenotype: A, B, AB, O, or unknown"}
|
|
65
|
+
- {name: ABO_genotype, description: "Diplotype label (for example A/O), or ambiguous"}
|
|
66
|
+
- {name: ABO_allele1, description: "First haplotype allele after alphabetical sort (A < B < O)"}
|
|
67
|
+
- {name: ABO_allele2, description: "Second haplotype allele after alphabetical sort"}
|
|
68
|
+
- {name: haplotype1, description: "Haplotype call on chromosome copy 1"}
|
|
69
|
+
- {name: haplotype2, description: "Haplotype call on chromosome copy 2"}
|
|
70
|
+
- {name: method, description: "Inference method used for this sample"}
|
|
71
|
+
- {name: geno_mode, description: "Genotype interpretation mode (hardcall, dosage, probability, auto)"}
|
|
72
|
+
- {name: phase_mode, description: "Whether haplotypes used phase (phased) or enumeration (unphased)"}
|
|
73
|
+
- {name: build, description: "Genome assembly used for marker coordinates"}
|
|
74
|
+
- {name: confidence, description: "high, medium, low, or none (not a calibrated probability)"}
|
|
75
|
+
- {name: qc_status, description: "PASS, AMBIGUOUS, MISSING_MARKER, CONFLICT, or LOW_CONFIDENCE"}
|
|
76
|
+
- {name: qc_reason, description: "Free-text explanation of QC status"}
|
|
77
|
+
- {name: possible_diplotypes, description: "Compatible diplotypes when ABO_genotype is ambiguous"}
|
|
78
|
+
- {name: ukb_haplotype, description: "UK Biobank Field 23165 haplotype code (ukb method only)"}
|
|
79
|
+
- {name: isbt_alleles, description: "Matched ISBT allele IDs (extended method only)"}
|
|
80
|
+
|
|
81
|
+
limitations:
|
|
82
|
+
- >-
|
|
83
|
+
Common A/B/O/AB inference uses four SNP markers and six common diplotypes under
|
|
84
|
+
standard assumptions. Rare, weak, cis-AB, null, hybrid, and structural ABO alleles
|
|
85
|
+
may be misclassified.
|
|
86
|
+
- >-
|
|
87
|
+
Non-deletional O alleles are not modelled. The extended method is limited to
|
|
88
|
+
ABO*A.01, ABO*B.01, and ABO*O.01; it is not ISBT-comprehensive.
|
|
89
|
+
- >-
|
|
90
|
+
rs505922 is an LD proxy for the O haplotype, not a functional variant. When it is
|
|
91
|
+
used (UKB fallback), confidence is capped at low.
|
|
92
|
+
- >-
|
|
93
|
+
On GRCh37/GRCh38 the reference allele at rs8176719 is the O-associated sequence.
|
|
94
|
+
VCF files often encode an insertion for A/B rather than a deletion for O;
|
|
95
|
+
normalization is required and representation varies by pipeline.
|
|
96
|
+
- >-
|
|
97
|
+
The default --assume-bo rule (O deletion on an A background, resolving
|
|
98
|
+
unphased double heterozygotes to B/O rather than A/O) is a common-allele
|
|
99
|
+
assumption. On 1000 Genomes 30x hg38 (phased GT, not serology), AMR/EAS/EUR
|
|
100
|
+
double-hets were all B/O; AFR 8/113 were A/O. Pass --no-assume-bo to mark
|
|
101
|
+
those samples ambiguous.
|
|
102
|
+
- >-
|
|
103
|
+
Low imputation INFO, missing genotypes, and uncertain dosages propagate to
|
|
104
|
+
low-confidence or unknown calls.
|
|
105
|
+
- >-
|
|
106
|
+
genoABO has not been validated against serological typing across ancestries.
|
|
107
|
+
Outputs are intended for population-genetics, epidemiology, GWAS, PheWAS, and
|
|
108
|
+
biobank research.
|
|
109
|
+
|
|
110
|
+
determination:
|
|
111
|
+
intro: >-
|
|
112
|
+
ABO phenotype is inferred from biological marker states after REF/ALT
|
|
113
|
+
normalization, not from raw VCF alleles. The selected method of this run
|
|
114
|
+
is named below; unused markers are shown for reference.
|
|
115
|
+
marker_roles:
|
|
116
|
+
caption: Tag SNPs used for ABO inference and their biological states.
|
|
117
|
+
columns: [Marker, HGVS, States, Role]
|
|
118
|
+
rows:
|
|
119
|
+
- [rs8176719, "c.261delG", "O_DEL / NON_O", "O vs A/B background"]
|
|
120
|
+
- [rs8176746, "c.796C>A", "A_ALLELE / B_ALLELE", "A vs B"]
|
|
121
|
+
- [rs8176747, "c.803G>C", "A_ALLELE / B_ALLELE", "A vs B confirmation (three-marker)"]
|
|
122
|
+
- [rs505922, "—", "O_PROXY / NON_O_PROXY", "LD proxy for O (ukb only; not functional)"]
|
|
123
|
+
haplotype:
|
|
124
|
+
caption: Haplotype call on each chromosome copy.
|
|
125
|
+
columns: [Condition, Haplotype]
|
|
126
|
+
rows:
|
|
127
|
+
- ["rs8176719 = O_DEL", O]
|
|
128
|
+
- ["else rs8176746 = B_ALLELE (and rs8176747 = B_ALLELE when three-marker)", B]
|
|
129
|
+
- ["else rs8176746 = A_ALLELE", A]
|
|
130
|
+
- ["else", unknown]
|
|
131
|
+
note: >-
|
|
132
|
+
If rs8176746 and rs8176747 disagree on B vs A, a QC warning is raised and
|
|
133
|
+
confidence is low.
|
|
134
|
+
diplotype_from_markers:
|
|
135
|
+
caption: >-
|
|
136
|
+
Unphased diploid combinations of rs8176719 and rs8176746 (common and
|
|
137
|
+
three-marker). States are biological, not REF/ALT.
|
|
138
|
+
columns: [rs8176719, rs8176746, Diplotype, Phenotype]
|
|
139
|
+
rows:
|
|
140
|
+
- ["O_DEL / O_DEL", any, O/O, O]
|
|
141
|
+
- ["NON_O / NON_O", "A / A", A/A, A]
|
|
142
|
+
- ["O_DEL / NON_O", "A / A", A/O, A]
|
|
143
|
+
- ["NON_O / NON_O", "B / B", B/B, B]
|
|
144
|
+
- ["O_DEL / NON_O", "A / B", B/O, "B (--assume-bo default)"]
|
|
145
|
+
- ["NON_O / NON_O", "A / B", A/B, AB]
|
|
146
|
+
notes:
|
|
147
|
+
- "three-marker also requires rs8176747 to agree with rs8176746."
|
|
148
|
+
- "ukb may substitute rs505922 as an O proxy; confidence is then capped at low."
|
|
149
|
+
- "Inference rules never operate on raw VCF REF/ALT."
|
|
150
|
+
- "--no-assume-bo leaves O_DEL/NON_O × A/B ambiguous (A/O or B/O)."
|
|
151
|
+
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "genoabo"
|
|
7
|
+
version = "0.1.0"
|
|
8
|
+
description = "Genetically determined ABO blood group inference from genotype datasets"
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
license = "MIT"
|
|
11
|
+
requires-python = ">=3.11"
|
|
12
|
+
authors = [{ name = "Yunye He" }]
|
|
13
|
+
keywords = ["ABO", "blood-group", "genotype", "GWAS", "biobank", "bioinformatics"]
|
|
14
|
+
classifiers = [
|
|
15
|
+
"Development Status :: 4 - Beta",
|
|
16
|
+
"Intended Audience :: Science/Research",
|
|
17
|
+
"License :: OSI Approved :: MIT License",
|
|
18
|
+
"Programming Language :: Python :: 3",
|
|
19
|
+
"Programming Language :: Python :: 3.11",
|
|
20
|
+
"Programming Language :: Python :: 3.12",
|
|
21
|
+
"Topic :: Scientific/Engineering :: Bio-Informatics",
|
|
22
|
+
]
|
|
23
|
+
dependencies = [
|
|
24
|
+
"cyvcf2>=0.30",
|
|
25
|
+
"Pgenlib>=0.94",
|
|
26
|
+
"bgen-reader>=4.0",
|
|
27
|
+
"numpy>=1.24",
|
|
28
|
+
"pyyaml>=6.0",
|
|
29
|
+
"typer>=0.9",
|
|
30
|
+
"rich>=13.0",
|
|
31
|
+
]
|
|
32
|
+
|
|
33
|
+
[project.optional-dependencies]
|
|
34
|
+
dev = [
|
|
35
|
+
"pytest>=7.4",
|
|
36
|
+
"pytest-cov>=4.1",
|
|
37
|
+
"ruff>=0.1",
|
|
38
|
+
"mypy>=1.5",
|
|
39
|
+
"types-PyYAML>=6.0",
|
|
40
|
+
]
|
|
41
|
+
bgenix = ["bgenix>=1.1"]
|
|
42
|
+
docs = ["zensical"]
|
|
43
|
+
|
|
44
|
+
[project.scripts]
|
|
45
|
+
genoabo = "genoabo.cli:main"
|
|
46
|
+
|
|
47
|
+
[project.urls]
|
|
48
|
+
Homepage = "https://github.com/cloufield/genoABO"
|
|
49
|
+
Repository = "https://github.com/cloufield/genoABO"
|
|
50
|
+
|
|
51
|
+
[tool.hatch.build.targets.wheel]
|
|
52
|
+
packages = ["src/genoabo"]
|
|
53
|
+
|
|
54
|
+
[tool.hatch.build.targets.sdist]
|
|
55
|
+
include = ["src/genoabo/data/*"]
|
|
56
|
+
|
|
57
|
+
[tool.pytest.ini_options]
|
|
58
|
+
testpaths = ["tests"]
|
|
59
|
+
addopts = "-v --tb=short"
|
|
60
|
+
|
|
61
|
+
[tool.ruff]
|
|
62
|
+
line-length = 100
|
|
63
|
+
target-version = "py311"
|
|
64
|
+
|
|
65
|
+
[tool.ruff.lint]
|
|
66
|
+
select = ["E", "F", "I", "W"]
|
|
67
|
+
ignore = ["E501"]
|
|
68
|
+
|
|
69
|
+
[tool.mypy]
|
|
70
|
+
python_version = "3.11"
|
|
71
|
+
warn_return_any = true
|
|
72
|
+
warn_unused_configs = true
|
|
73
|
+
ignore_missing_imports = true
|
|
74
|
+
|
|
75
|
+
[tool.hatch.build]
|
|
76
|
+
sources = ["src"]
|