Created
May 23, 2022 20:44
-
-
Save mtholder/b04aeae9cb571a02d3f6e6efc104eaff to your computer and use it in GitHub Desktop.
grab the newick trees from timetree for your personal research and teaching use. Assumes https://gist.github.com/mtholder/615f1f77af9b7db8f0f9220fa514ab07 in same dir
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
#!/bin/bash | |
curl 'http://www.timetree.org/references' > studies.html | |
grep citation_data studies.html | sed -E 's:.*citation_data/::' | sed -E 's/".*//' > ids.txt | |
for i in `cat ids.txt` ; do | |
echo $i | |
if ! test -f "${i}.tre" ; then | |
python grab.py "$i" > "${i}.tre" || exit 1 | |
fi | |
sleep 2 | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment