DAVIDQuery: DAVIDQuery

Description Usage Arguments Details Value Author(s) References See Also Examples

Description

Launch a query against DAVID, the Database for Annotation, Visualization and Integrated Discovery. Return the results into an R object.

Usage

1
2
DAVIDQuery(ids = "O00161,O75396", type = "UNIPROT_ACCESSION", annot, tool, URLlengthLimit = 2048,
details = TRUE, verbose = FALSE, writeHTML = FALSE, testMe = FALSE, graphicMenu = FALSE,  formatIt = TRUE)

Arguments

ids

IDs for desired objects, as a character vector or as a single string with ids separated by ",". To be passed to the DAVID website, the format has to be the latter.

type

Type of input ids. If missing, a menu is contructed from the R object DAVIDTypeChoices. See http://david.abcc.ncifcrf.gov/content.jsp?file=DAVID_API.html#input_list for up-to-date choices.

annot

Type of annotation requested. If missing, a menu is contructed from the R object DAVIDAnnotChoices. See http://david.abcc.ncifcrf.gov/content.jsp?file=DAVID_API.html#input_list for up-to-date choices.

tool

Type of gene tool to use. If missing, a menu is contructed from the R object DAVIDToolChoices. See http://david.abcc.ncifcrf.gov/content.jsp?file=DAVID_API.html#input_list for up-to-date choices. As of this writing, the tool choices corresponding to the Functional Annotation tools cannot be handled by this package.

URLlengthLimit

Published maximum length of the constructed URL.

details

If TRUE (default), a list of intermediate results is returned; otherwise, just the final query result.

verbose

If TRUE (default is FALSE), more debugging information is printed.

writeHTML

If TRUE (default is FALSE), write the received intermediate HTML to files.

testMe

If TRUE (default is FALSE), assign default valuse and run.

graphicMenu

If TRUE (default is FALSE), use a GUI window for the pick menus.

formatIt

If TRUE (default), try to interpret the returned character table and structure the result. If false, the unadorned character table returned by DAVID.

Details

The API described at http://david.abcc.ncifcrf.gov/content.jsp?file=DAVID_API.html is used. The return is screen-scraped, a new URL is formulated and transmitted, again the return is screen-scraped to find the name of the results file, and finally that file is retrieved into a string matrix.

Obviously this approach is brittle, but it has survived the 2008 DAVID update. A real API would be better, of course.

The return value DAVIDQueryResult is just a character matrix. Its content structure depends on the choices of tool and annotation arguments, so there has been no attempt to manipulate it into, say, a data frame with nice column names.

Value

If detail==FALSE, only DAVIDQueryResult is returned. This a character matrix holding the results of the tab-delimited file returned by DAVID.

If detail==TRUE, a list with contents useful for trouble-shooting:

firstURL
firstStageResult
DAVIDaction
secondURL
secondStageResult
hasSessionEnded
downloadFileName
downloadURL
DAVIDQueryResult

Author(s)

Roger Day

References

http://david.abcc.ncifcrf.gov http://david.abcc.ncifcrf.gov/content.jsp?file=DAVID_API.html Article: DAVID gene ID conversion tool. Da Wei Huang, Brad T Sherman, Robert Stephens, Michael W Baseler, H Clifford Lane, and Richard A Lempicki http://www.pubmedcentral.nih.gov/articlerender.fcgi?tool=pubmed&pubmedid=18841237

See Also

DAVIDQueryLoop, formatDAVIDResult

Examples

1
2
3
4
5
6
7
result = DAVIDQuery(testMe=TRUE)
print(names(result))
print(result$firstURL)
print(result$secondURL)
print(names(result$DAVIDQueryResult))
print(names(result$DAVIDQueryResult$O00161))
print(result$DAVIDQueryResult$O00161$GENE_SYMBOL)  ### Uses UNIPROT ID's for input.

DAVIDQuery documentation built on Sept. 12, 2016, 6:11 a.m.