ds.log {dsBaseClient}R Documentation

Computes logarithms, by default natural logarithms

Description

This function is similar to R function log.

Usage

ds.log(x = NULL, base = exp(1), newobj = NULL, datasources = NULL)

Arguments

x

a vector.

base

a numrical, the base with respect to which logarithms are computed.

newobj

the name of the new variable. If this argument is set to NULL, the name of the new variable is the name of the input variable with the suffixe '_log' (e.g. 'LAB_TSC_log', if input variable's name is 'LAB_TSC')

datasources

a list of opal object(s) obtained after login in to opal servers; these objects hold also the data assign to R, as dataframe, from opal datasources.

Details

this is simply a wrapper for the server side function.

Value

nothing is returned to the client, the new object is stored on the server side.

Author(s)

Gaye, A.; Isaeva, J.

Examples

{

  # load that contains the login details
  data(logindata)

  # login and assign specific variable(s)
  myvar <- list("LAB_TSC")
  opals <- datashield.login(logins=logindata,assign=TRUE,variables=myvar)

  # Compute natural logarithm of LAB_TSC
  ds.log(x='D$LAB_TSC')

  # clear the Datashield R sessions and logout
  datashield.logout(opals)

}

[Package dsBaseClient version 4.1.0 ]