Skip to content

Instantly share code, notes, and snippets.

@reiaoki
reiaoki / search_biopython.py
Created October 31, 2017 22:18 — forked from bonzanini/search_biopython.py
Searching PubMed with Biopython
# you need to install Biopython:
# pip install biopython
# Full discussion:
# https://marcobonzanini.wordpress.com/2015/01/12/searching-pubmed-with-python/
from Bio import Entrez
def search(query):
Entrez.email = '[email protected]'
@reiaoki
reiaoki / pubmedLookup.py
Last active October 4, 2023 12:40
Searcch pubmed using Bio.Entrez, write results on a CSV file
#serach pubmed with a keywword, write specific information on a CSV file using E Utilities
from Bio import Entrez
import csv
def search(query):
#provide NCBI your email address
Entrez.email = '[email protected]'
#get the list of IDs
searchHandle = Entrez.esearch(db='pubmed',