Learn R Programming

reutils (version 0.1.0)

content: Extract the data content from an Entrez request

Description

There are three ways to access data returned by an Entrez request: as a character string (as = "text"), as a parsed XML tree (as = "xml"), or, if supported, parsed into a native R object, e.g. a list or a data.frame (as = "parsed").

Arguments

x
An eutil object.
as
Type of output: "xml", "text", or "parsed".
...
Further arguments passed on to methods.

See Also

einfo, esearch, esummary, efetch, elink, epost, egquery, espell, ecitmatch.

Examples

Run this code
e <- einfo()

## return XML as an 'XMLInternalDocument'.
content(e, "xml")

## return XML as character string.
cat(content(e, "text"))

## return DbNames parsed into a character vector.
content(e, "parsed")

Run the code above in your browser using DataLab