|
| 1 | +id: https://w3id.org/linkml/examples/enums |
| 2 | +title: Dynamic Enums Example |
| 3 | +name: dynamicenums-example |
| 4 | +description: This demonstrates the use of dynamic enums |
| 5 | +license: https://creativecommons.org/publicdomain/zero/1.0/ |
| 6 | + |
| 7 | +prefixes: |
| 8 | + linkml: https://w3id.org/linkml/ |
| 9 | + ex: https://w3id.org/linkml/examples/enums/ |
| 10 | + sh: https://w3id.org/shacl/ |
| 11 | + bioregistry: https://bioregistry.io/registry/ |
| 12 | + MONDO: http://purl.obolibrary.org/obo/MONDO_ |
| 13 | + NCIT: http://purl.obolibrary.org/obo/NCIT_ |
| 14 | + loinc: http://loinc.org/ |
| 15 | + |
| 16 | +default_prefix: ex |
| 17 | +default_range: string |
| 18 | + |
| 19 | +default_curi_maps: |
| 20 | + - semweb_context |
| 21 | + |
| 22 | +emit_prefixes: |
| 23 | + - linkml |
| 24 | + - rdf |
| 25 | + - rdfs |
| 26 | + - xsd |
| 27 | + - owl |
| 28 | + |
| 29 | +imports: |
| 30 | + - linkml:types |
| 31 | + |
| 32 | + |
| 33 | +#================================== |
| 34 | +# Classes # |
| 35 | +#================================== |
| 36 | + |
| 37 | +classes: |
| 38 | + HumanSample: |
| 39 | + slots: |
| 40 | + - name |
| 41 | + - disease |
| 42 | + |
| 43 | + |
| 44 | +#================================== |
| 45 | +# Slots # |
| 46 | +#================================== |
| 47 | + |
| 48 | +slots: |
| 49 | + name: |
| 50 | + range: string |
| 51 | + disease: |
| 52 | + range: HumanDisease |
| 53 | + vital_status: |
| 54 | + enum_range: |
| 55 | + permissible_values: |
| 56 | + LIVING: |
| 57 | + DEAD: |
| 58 | + UNDEAD: |
| 59 | + |
| 60 | +#================================== |
| 61 | +# Enums |
| 62 | +#================================== |
| 63 | + |
| 64 | +enums: |
| 65 | + Disease: |
| 66 | + reachable_from: |
| 67 | + source_ontology: bioregistry:mondo |
| 68 | + source_nodes: |
| 69 | + - MONDO:0000001 ## disease or disorder |
| 70 | + is_direct: false |
| 71 | + relationship_types: |
| 72 | + - rdfs:subClassOf |
| 73 | + minus: |
| 74 | + - permissible_values: |
| 75 | + root_node: |
| 76 | + meaning: MONDO:0000001 ## disease or disorder |
| 77 | + |
| 78 | + HumanDisease: |
| 79 | + description: Extends the Disease value set, including NCIT neoplasms, excluding non-human diseases |
| 80 | + inherits: |
| 81 | + - Disease |
| 82 | + include: |
| 83 | + - reachable_from: |
| 84 | + source_ontology: bioregistry:ncit |
| 85 | + source_nodes: |
| 86 | + - NCIT:C3262 |
| 87 | + minus: |
| 88 | + - reachable_from: |
| 89 | + source_ontology: bioregistry:mondo |
| 90 | + source_nodes: |
| 91 | + - MONDO:0005583 ## non-human animal disease |
| 92 | + relationship_types: |
| 93 | + - rdfs:subClassOf |
| 94 | + - permissible_values: |
| 95 | + NOT_THIS_ONE: |
| 96 | + meaning: MONDO:9999 |
| 97 | + description: Example of excluding a single node |
| 98 | + |
| 99 | + LoincExample: |
| 100 | + enum_uri: http://hl7.org/fhir/ValueSet/example-intensional |
| 101 | + see_also: |
| 102 | + - https://build.fhir.org/valueset-example-intensional.json.html |
| 103 | + include: |
| 104 | + - reachable_from: |
| 105 | + source_ontology: "loinc:" |
| 106 | + source_nodes: |
| 107 | + - loinc:LP43571-6 |
| 108 | + is_direct: true |
| 109 | + minus: |
| 110 | + - concepts: |
| 111 | + - LOINC:5932-9 |
| 112 | + |
| 113 | + HCAExample: |
| 114 | + see_also: |
| 115 | + - https://github.com/linkml/linkml/issues/274 |
| 116 | + include: |
| 117 | + - reachable_from: |
| 118 | + source_ontology: bioregistry:go |
| 119 | + source_nodes: |
| 120 | + - GO:0007049 |
| 121 | + - GO:0022403 |
| 122 | + include_self: false |
| 123 | + relationship_types: |
| 124 | + - rdfs:subClassOf |
| 125 | + minus: |
| 126 | + - concepts: |
| 127 | + - LOINC:5932-9 |
| 128 | + |
| 129 | + BodyPartEnum: |
| 130 | + reachable_from: |
| 131 | + source_ontology: obo:cl |
| 132 | + source_nodes: |
| 133 | + - CL:0000540 ## neuron |
| 134 | + include_self: false |
| 135 | + relationship_types: |
| 136 | + - rdfs:subClassOf |
| 137 | + |
| 138 | + Brand: |
| 139 | + enum_uri: wikidata:Q431289 |
| 140 | + include: |
| 141 | + - reachable_from: |
| 142 | + source_ontology: bioregistry:wikidata |
| 143 | + source_nodes: |
| 144 | + - wikidata:Q431289 |
| 145 | + include_self: false |
| 146 | + relationship_types: |
| 147 | + - wdp:P31 |
| 148 | + - wdp:P279 |
| 149 | + |
| 150 | + SerumCholesterolExample: |
| 151 | + description: > |
| 152 | + This is an example value set that includes all the LOINC codes for serum/plasma cholesterol from v2.36. |
| 153 | + code_set: http://hl7.org/fhir/ValueSet/serum-cholesterol |
| 154 | + code_set_version: "1.0.0" |
| 155 | + pv_formula: CODE |
| 156 | + include: |
| 157 | + - concepts: |
| 158 | + - LP43571-6 |
| 159 | + minus: |
| 160 | + - concepts: |
| 161 | + - 5932-9 |
| 162 | + reachable_from: |
| 163 | + source_ontology: http://loinc.org |
| 164 | + source_nodes: |
| 165 | + - LP43571-6 |
| 166 | + relationship_types: null |
| 167 | + is_direct: true |
| 168 | + include_self: true |
| 169 | + traverse_up: false |
| 170 | + concepts: |
| 171 | + - http://loinc.org/LP43571-6 |
0 commit comments