1

有没有办法使用 Biopython 找出数据库的更新状态?

我正在尝试做这样的事情;

  1. 我有一个 100000 个医学术语的列表

  2. 7 月 1 日,我检索了所有 100000 个术语的 ID 列表。

  3. 今天(7 月 3 日)我想知道是否为 100000 个术语中的任何一个添加了新文章。

一种方法是重复整个过程(获取所有 100000 个术语),如下所示;

'termlist' = ['Malaria', 'Flu' ,...........]

for term in termlist:
    handle = Entrez.esearch(db = "pubmed", term = 'Malaria')
    record = Entrez.read(handle)
    record['Count']

有没有办法只找出今天在 pubmed 中更新的条款?

如果我的条款是更新列表的一部分,我只需要搜索更新的条款,而不是所有 100000 个条款。

4

1 回答 1

1

这里有与搜索相关的所有参数:

http://www.ncbi.nlm.nih.gov/books/NBK25499/#chapter4.ESearch

您对以下内容感兴趣:reldate、datetype、mindate 和 maxdate。如果您将这些参数传递给 esearch 命令,Biopython 只需将它们插入 NCBI 查询。

# Retrieve the entries of the last 3 days
handle = Entrez.esearch(db = "pubmed", term = 'Malaria',
                        datetype = "edat", reldate = 3)

# Retrieve the entries between two dates:
handle = Entrez.esearch(db = "pubmed", term = 'Malaria',
                        mindate = "2014/07/03", maxdate = "2014/07/01")

此外,您可以通过使用以下语法连接术语来加快查询过程:

term = "Malaria+OR+Cancer+OR+Anopheles"
于 2014-07-03T17:42:01.530 回答