entrez_search: Search the NCBI databases using EUtils

Description Usage Arguments Value Examples

View source: R/entrez_search.r

Description

Contstructs a query with the given arguments, including a search term, and a darabase name, then retrieves the XML document created by that query. See package-level documentation for general advice on using the Entrez functions

Usage

1
  entrez_search(db, term, ...)

Arguments

db

character Name of the database to search for

term

character The search term

...

character Additional terms to add to the request

Value

ids integer Unique IDS returned by the search

count integer Total number of hits for the search

retmax integer Maximum number of hits returned by the search

QueryKey integer identifier for specific query in webhistory

WebEnv character identifier for session key to use with history

file XMLInternalDocument xml file resulting from search, parsed with xmlTreeParse

Examples

1
2
3
4
5
6
7
8
9
## Not run: 
   web_env_search <- entrez_search(db="nuccore",
                                   term="Gastropoda[Organism] AND COI[Gene]",#'                                    usehistory="y")
  cookie <- web_env_search$WebEnv
  qk <- web_env_search$QueryKey
  snail_coi <- entrez_fetch(db = "nuccore", WebEnv = cookie, query_key = qk,
                             file_format = "fasta", retmax = 10)

## End(Not run)

rentrez documentation built on May 2, 2019, 6:12 p.m.