# Version 4.0.0

(Link back to Version 4 Archive)

## Contents

# Functions amended

##### ds.glm

New parameters (i.e. arguments) added to the function:

: **ds.glm**

, **data**

and **weights**

, **offset**

, **checks**

.**startBetas**

allows for user to specify the name of an optional data frame that holds the variables in the regression formula so one can can write for example:**data**which is equivalent to

In the previous release only the latter command was possible when the variables in the regression formula were held in a data frame 'D'.

to specify the name of a numeric variable of 'prior weights' to be used in the model fitting process.**weights**

to specify the name of a known component to be included in the linear predictor.**offset**

to help with error tracking. These checks are switched off by default. If set to**checks***TRUE*thorough checks are carried out before the process starts.

to specify starting values for the parameters in the linear predictor. In earlier versions this parameter was named**startBetas**

.**startCoeff**

##### ds.table1D and ds.table2D

The Functions were re-written from scratch to implement a new way of masking 'invalid' cells whilst reporting correct total counts (i.e. to address the issues raised in BioSHaRe annual meeting, Athens 2014).

The new versions of these two functions return a more tidy output with improved error reporting and improved flexibility.

##### ds.tTest

In the previous version of this function a t.test was only possible for two continuous vectors.

The new version allows for the comparison of the mean values of a continuous vector across the categories of factor as in the below example where both vectors are in a data frame 'D':

##### ds.dataframe

New parameter (i.e. argument) added to the function:

:**completeCases**

if set to**completeCases***TRUE*allows to construct a complete table (i.e. a data frame where rows with missing values are excluded)

##### ds.meanByClass

In the new version of this function it is possible to compute the mean and standard deviation of a continuous vector across the categories of a factor as follows:

This addition was implemented for improved flexibility and is equivalent to the below syntax which still works and should be used to specify more than one outcome or covariate.

# New functions

##### ds.subsetByClass

This function replaces the previous **ds.subclass**

##### ds.numNA

Returns the number of missing values in a given vector.

##### ds.replaceNA

To replaces missing values in a given vector by specific value(s).

##### ds.ls

To display the names of the objects stored/defined on the server side.

### Functions removed

##### ds.subclass

This function has been replaced by **ds.subsetByClass**

# Actions required from users

- Some of the changes listed above might affect your previous scripts/commands, particularly the change of function names and syntax (e.g.

replaced by**ds.subclass**

). Please amend your previous scripts/commands to adopt the new functions names and syntax to avoid errors.**ds.subsetByClass**

- If you are faced with an error whilst using this new version please double check first that you are using the correct function name and syntax before contacting the support team. This will ensure our limited support resources are used efficiently.

# Actions required from opal server administrators

If you are the administrator of the opal server for a cohort: Please deploy the new package in your servers. Install all the packages via opal as follows:

- Login in to your opal interface
- Go to

on top-right corner**Administration** - select
**DataSHIELD** - In the packages list:
- remove remove all the packages

2. click**Add Package**

3. click**Install**

4. wait...

5. verify that all package version are 4.0.0

6. next to each package and under the column

, click on**Action****Publish methods**

- remove remove all the packages

### List of packages and functions in the version 4.0.0

A /wiki/spaces/DSDEV/pages/12943456 is available.