Visualize Schema¶
biothings_schema pyton package allows you to visualize your own schema.
Visualize the Full Schema as a Tree¶
In [1]: from biothings_schema import Schema
In [2]: schema_url = 'https://raw.githubusercontent.com/data2health/schemas/biothings/biothings/biothings_curie_kevin.jsonld'
In [3]: se = Schema(schema=schema_url)
In [4]: se.full_schema_graph()
# A tree structured graph of your schema would be displayed
Visulize the ancestors of a specific class¶
biothings_schema python package also accepts URL as its input. The data loaded from the URL must be either a JSON document or a YAML document.
In [1]: se.sub_schema_graph(source='GenomicEntity', include_children=False, include_parents=True)
Visulize the descendants of a specific class¶
In [1]: se.sub_schema_graph(source='GenomicEntity', include_children=True, include_parents=False)
Visulize the full ancestry of a specific class¶
In [1]: se.sub_schema_graph(source='GenomicEntity', size="9,6")