This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import bioregistry | |
def main(): | |
"""Identify resources with uncurated bananas.""" | |
for resource in bioregistry.resources(): | |
pattern = resource.get_pattern() | |
if not pattern: | |
continue | |
for peel in ":_-": |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Get Journal of Cheminformatics DOIs.""" | |
import requests | |
import pystow | |
MODULE = pystow.module("jcheminf", "volumes") | |
USER = "egonw" # alternative use first-party jcheminform if it ever gets updated | |
REPO = "jcheminform-kb" | |
BRANCH = "main" | |
PREFIX = "https://doi.org/10.1186/" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Update the dependencies.""" | |
import json | |
from pathlib import Path | |
from typing import Iterable, Optional | |
import bioontologies | |
import bioregistry | |
import click | |
from bioontologies.obograph import Graph |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Calculate the number of possible mappings between bioregistry entries.""" | |
from itertools import combinations | |
from bioregistry.external.getters import GETTERS | |
from bioregistry.version import VERSION | |
from humanize import intword | |
def main(): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#defaultView:Graph | |
SELECT ?s ?sLabel ?rgb ?edgelabel ?o ?oLabel | |
WHERE { | |
{ | |
SELECT ?s ?sLabel ?rgb ?o ?oLabel | |
WHERE { | |
?o wdt:P50 wd:Q47475003, ?s . | |
FILTER (?s != wd:Q47475003) | |
OPTIONAL { |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pathlib import Path | |
import pandas as pd | |
import pybiopax | |
ALL_PATHWAYS = "https://reactome.org/download/current/ReactomePathways.txt" | |
def download_reactome(directory): |