Description Usage Arguments Details Value See Also Examples
View source: R/retrieveEdgeList.R
'retrieveEdgeList' Retrieves a citation network edge list for a set of PMIDs
1 2 | retrieveEdgeList(pmids, batchSize = 200, conMysql = NULL,
lastUpdate = NULL)
|
pmids |
a vector of PMIDs look-up. |
batchSize |
the batch size to use for NCBI look-ups. |
conMysql |
a MySQL connection |
lastUpdate |
date string, in YYYY-MM-DD format, to use a threshold for updating target PMIDs in the database |
This function works as follows:
1. If a MySQL connection is not specified, retreive citation information from NCBI.
2. If a MySQL connection is specified and 'lastUpdate' is not NULL, then get the edge list from the database, for targets that have been updated after 'lastUpdate'. If 'lastUpdate' is NULL, then all target PMIDS in the database are used. For other target PMIDs, get citation information from NCBI.
If a MySQL connection is specified, the updated edge list and target PMIDs are stored in the database. Note that if a target PMID is updated, previous records with that target PMID are deleted from the database.
An edge list (data.frame) with one column for Target PMIDS and one column for Source PMIDS.
get_pmc_cited_in
and generateEdgeList
for
obtaining edge_list citation results from NCBI
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | ## Not run:
pmid <- 21876761
pmids1 <- c(21876761, 311, 29463753, 21876726)
# This will create tables and insert edge list from one pmid "21876761",
# for a valid con_mysql
# This gets everything from NCBI if there is no database
res1 <- retrieveEdgeList(pmid, conMysql = con_mysql)
# This will not create new tables or insert edge list. This will just take everything from DB.
# res2 == res1
res2 <- retrieveEdgeList(pmid, conMysql = con_mysql)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.