CreateConnection: CreateConnection

View source: R/CreateConnection.R

CreateConnectionR Documentation

CreateConnection

Description

Constructor for ImmuneSpaceConnection class.

Usage

CreateConnection(
  study = NULL,
  login = NULL,
  password = NULL,
  verbose = FALSE,
  onTest = FALSE
)

Arguments

study

A "character" vector naming the study.

login

A "character". Optional argument. If there is no netrc file a temporary one can be written by passing login and password of an active ImmuneSpace account.

password

A "character". Optional. The password for the selected login.

verbose

A "logical" whether to print the extra details for troubleshooting.

onTest

A "logical" whether to connect to the test server (https://datatools-dev.immunespace.org/) instead of the production server (https://datatools.immunespace.org/).

Details

Instantiates an ImmuneSpaceConnection for study The constructor will try to take the values of the various 'labkey.*' parameters from the global environment. If they don't exist, it will use default values. These are assigned to 'options', which are then used by the ImmuneSpaceConnection class.

Value

an instance of an ImmuneSpaceConnection

See Also

ImmuneSpaceConnection

Examples

## Not run: 
# Single study
con <- CreateConnection("SDY269")
# Cross study
con <- CreateConnection("")

## End(Not run)

sdy <- try(CreateConnection("SDY269"))
if (inherits(sdy, "try-error")) {
  warning("Read the Introduction vignette for more information on how to set
up a .netrc file.")
}

RGLab/ImmuneSpaceR documentation built on Jan. 5, 2023, 10:24 a.m.