Skip to content

Instantly share code, notes, and snippets.

@kozo2
Created February 28, 2016 06:01
Show Gist options
  • Select an option

  • Save kozo2/6c90ba5ad449e90f96aa to your computer and use it in GitHub Desktop.

Select an option

Save kozo2/6c90ba5ad449e90f96aa to your computer and use it in GitHub Desktop.
Cytoscape v3.3 Animation/Automation Challenge with Kaizu 2010
from bs4 import BeautifulSoup
soup = BeautifulSoup(open("./msb201073-sup-0003.xml", encoding='utf-8').read(), 'xml')
ann = soup.annotation
import re
sas = ann.find_all(re.compile("speciesAlias$"))
for sa in sas:
print(sa.get("id"), sa.bounds.get("h"), sa.bounds.get("w"), tag.bounds.get("x"), tag.bounds.get("y"))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment