R/registerDataSource.R

Defines functions registerDataSource

Documented in registerDataSource

registerDataSource <- function(code=NA,name=NA){
  datasource = NULL
  if (is.na(name) || is.na(code)) {
    stop("You must provide both a name or a system code")
  } else {
    builder <- .jcall(
     "org/bridgedb/DataSource",
     "Lorg/bridgedb/DataSource$Builder;",
     "register", code, name
    )
    datasource <- builder$asDataSource()
  }
  datasource
}

Try the BridgeDbR package in your browser

Any scripts or data that you put into this service are public.

BridgeDbR documentation built on Nov. 1, 2018, 3:47 a.m.