open_umls_hierarchy
- open_umls_hierarchy(version=None, *, api_key=None, force=False)[source]
Ensure and open a UMLS file from the given version.
- Parameters:
version (
Optional
[str
]) – The version of UMLS to ensure. If not given, is looked up withbioversions
.api_key (
Optional
[str
]) – An API key. If not given, is looked up usingpystow.get_config()
with theumls
module andapi_key
key.force (
bool
) – Should the file be re-downloaded, even if it already exists?
- Yields:
The file, which is used in the context manager.
This file contains the following columns:
CUI
Unique identifier of concept
AUI
Unique identifier of atom - variable length field, 8 or 9 characters
CXN
Context number (e.g., 1, 2, 3)
PAUI
Unique identifier of atom’s immediate parent within this context
SAB
Abbreviated source name (SAB) of the source of atom
RELA
Relationship of atom to its immediate parent
PTR
Path to the top or root of the hierarchical context from this atom.
HCD
Source asserted hierarchical number or code for this atom in this context.
CVF
Content View Flag. Bit field used to flag rows included in Content View.