Controlled Vocabulary Utils
A package for evaluating values for terms in a controlled vocabulary.
Usage
Contents of the controlled vocabulary configuration file:
---
format_version: 0.1.0
name: Controlled Vocabulary for Bioinformatics
description: TBD
terms:
- name: variant_effect_on_function
def: The effect that the variant has on the function of the gene.
datatype: string
accepted_values:
"loss": The variant has caused a loss of function.
"gain": The variant has caused a gain of function.
- name: region_of_transcript_affected
def: The region of the transcript that the variant affects.
datatype: string
accepted_values:
"start": The variant affects the start of the transcript.
"end": The variant affects the end of the transcript.
"whole transcript": The variant affects the whole transcript.
"overlapping end": The variant overlaps one end of the ends of the transcript.
- name: variant_status
def: TBD
alt_names:
- variant_qc_status
datatype: string
accepted_values:
- name: score
def: TBD
datatype: integer
accepted_values:
"10": "very low score"
"20": "low score"
"40": "mid-level score"
- name: zygosity
def: TBD
alt_names:
- zyg
datatype: string
accepted_values:
"heterozygous": "heterozygous"
"homozygous": "homozygous"
"mosaic": "mosaic"
from controlled_vocabulary_utils import CVValidationManager
config_file = "conf/controlled_vocabulary.yaml"
vm = ValidationManager(
config_file=config_file,
verbose=verbose,
)
term = "zygosity"
val = "mosaic"
if vm.is_valid(term, val):
print(f"'{val}' is a valid value for term '{term}'")
else:
print(f"'{val}' is NOT a valid value for term '{term}'")
History
0.1.0 (2025-02-22)
First release on PyPI.
Metadata
Release files for controlled-vocabulary-utils 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| controlled_vocabulary_utils-0.3.0.tar.gz | 14.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| controlled_vocabulary_utils-0.3.0-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details |
Total release size: 23.2 kB
Release files / controlled_vocabulary_utils-0.3.0.tar.gz
| Download URL | controlled_vocabulary_utils-0.3.0.tar.gz |
|---|---|
| Size | 14.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e64375262637652b93c8b2209f63ad419682277d28a4a56c9aee1e68638314ff
|
|
BLAKE2b-256 checksum How to use checksums |
0df9fe71c2f2808b7506e2bf1f550ee3f504ec0485fbd2ab3a84fa9464830a76
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.10.12
|
Release files / controlled_vocabulary_utils-0.3.0-py2.py3-none-any.whl
| Download URL | controlled_vocabulary_utils-0.3.0-py2.py3-none-any.whl |
|---|---|
| Size | 9.1 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
f9e715597eef84656a12b157004a9cd684de2b4870f79694d874d9c1bff100cd
|
|
BLAKE2b-256 checksum How to use checksums |
d46811065c5bf2b38e911d5afd62523ad15dcd8d82f9fbef9215705d1a8c36c5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.10.12
|