fetchNode: Query nodes from the database

Description Usage Arguments Details Value Note Author(s) Examples

Description

query nodes from the database which will return node information or node attributes including neo4jid, grinnid, nodename, nodelabel, datasource, description, organism, synonyms and xref, if applicable.

Usage

1
fetchNode(txtinput, nodetype, searchby, exactmatch, returnas)

Arguments

txtinput

a character vector of entities. It can be the value of any node property key e.g. txtinput = c('pubchemId1', 'pubchemId2'), see also searchby.

nodetype

a string specifying a node type. It can be one of compound, protein, gene, pathway, rna, dna, phenotype.

searchby

a string specifying a node property key used for the query. It can be one of neo4jid (default), grinnid, name, synonyms, description, properties, xref, datasource.

exactmatch

a logical value. If TRUE (default), match exactly, case-sensitive and data type-sensitive.

returnas

a string specifying output type. It can be one of dataframe, list, json. Default is dataframe.

Details

The database uses two id systems. The neo4j id is a numeric, internal id automatically generated by the database system. The grinn id (gid) is an id system of Grinn database that uses main ids of standard resources i.e. ENSEMBL for genes (e.g.ENSG00000139618), UniProt for proteins (e.g.P0C9J6), PubChem CID for compounds (e.g.5793), KEGG for pathways (e.g.hsa00010).

Value

node information. Return empty list or data frame if error or found nothing.

Note

maximum no. of nodes returned = 30000 nodes

Author(s)

Kwanjeera W kwanich@ucdavis.edu

Examples

1
2
3
4
5
6
7
8
9
# Query compounds by name
#kw <- list('1-Methylhistidine','D-Lactic acid')
#result <- fetchNode(txtinput=kw, nodetype="compound", searchby="name")
# Query compounds by KEGG ids
#kw <- c('C01152','C00256','C00345')
#result <- fetchNode(txtinput=kw, nodetype="compound", searchby="xref")
# Query compounds by synonyms
#kw <- '1-Methyl histidine'
#result <- fetchNode(txtinput=kw, nodetype="compound", searchby="synonyms", exactmatch=FALSE)

kwanjeeraw/metabox documentation built on May 20, 2019, 7:07 p.m.