Skip to content

Commit 195e4b5

Browse files
Merge pull request #347 from datashield/v6.3.1-RC2-dev
Update with V6.3.1-RC2-dev
2 parents e206b3c + 32398a5 commit 195e4b5

213 files changed

Lines changed: 3567 additions & 3838 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

DESCRIPTION

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Package: dsBase
22
Title: DataSHIELD server site base functions
33
Description: DataSHIELD server site base functions.
4-
Version: 6.3.0
4+
Version: 6.3.1
55
Author: DataSHIELD Developers <datashield@liverpool.ac.uk>
66
Maintainer: DataSHIELD Developers <datashield@liverpool.ac.uk>
77
License: GPL-3
@@ -19,6 +19,8 @@ Imports:
1919
gamlss.dist,
2020
mice,
2121
childsds
22+
Suggests:
23+
testthat
2224
AggregateMethods:
2325
asFactorDS1,
2426
asListDS,
@@ -194,5 +196,5 @@ Options:
194196
default.nfilter.noise=0.25,
195197
default.nfilter.levels.density=0.33,
196198
default.nfilter.levels.max=40
197-
RoxygenNote: 7.2.3
199+
RoxygenNote: 7.3.2
198200
Encoding: UTF-8

R/asListDS.R

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,21 @@
22
#' @description Coerces an R object into a list
33
#' @details Unlike most other class coercing functions this is
44
#' an aggregate function rather than an assign function. This
5-
#' is because the {datashield.assign} function in the data repository deals specially with
5+
#' is because the \code{datashield.assign} function in the data repository deals specially with
66
#' a created object (newobj) if it is of class list. Reconfiguring the
77
#' function as an aggregate function works around this problem.
8-
#' This aggregate function is based on the native R function {as.list}
9-
#' and so additional information can be found in the help for {as.list}
8+
#' This aggregate function is based on the native R function \code{as.list}
9+
#' and so additional information can be found in the help for \code{as.list}
1010
#' @param x.name the name of the input object to be coerced to class
1111
#' data.matrix. Must be specified in inverted commas. But this argument is
1212
#' usually specified directly by <x.name> argument of the clientside function
13-
#' {ds.asList}
13+
#' \code{ds.asList}
1414
#' @param newobj is the object hard assigned '<<-' to be the output of the
1515
#' function written to the serverside
1616
#' @return the object specified by the <newobj> argument (or its default name
1717
#' <x.name>.mat) which is written to the serverside.
1818
#' In addition, two validity messages are returned. The first confirms an output
19-
#' object has been created, the second states its class. The way that {as.list}
19+
#' object has been created, the second states its class. The way that \code{as.list}
2020
#' coerces objects to list depends on the class of the object, but in general
2121
#' the class of the output object should usually be 'list'
2222
#' @author Amadou Gaye, Paul Burton for DataSHIELD Development Team

R/asLogicalDS.R

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
#' @title Coerces an R object into class numeric
2-
#' @description this function is based on the native R function {as.numeric}
3-
#' @details See help for function {as.logical} in native R
2+
#' @description this function is based on the native R function \code{as.numeric}
3+
#' @details See help for function \code{as.logical} in native R
44
#' @param x.name the name of the input object to be coerced to class
55
#' numeric. Must be specified in inverted commas. But this argument is
66
#' usually specified directly by <x.name> argument of the clientside function
7-
#' {ds.aslogical}
7+
#' \code{ds.aslogical}
88
#' @return the object specified by the <newobj> argument (or its default name
99
#' <x.name>.logic) which is written to the serverside. For further
10-
#' details see help on the clientside function {ds.asLogical}
10+
#' details see help on the clientside function \code{ds.asLogical}
1111
#' @author Amadou Gaye, Paul Burton for DataSHIELD Development Team
1212
#' @export
1313
asLogicalDS <- function (x.name){

R/asMatrixDS.R

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
#' @title Coerces an R object into a matrix
2-
#' @description this function is based on the native R function {as.matrix}
3-
#' @details See help for function {as.matrix} in native R
2+
#' @description this function is based on the native R function \code{as.matrix}
3+
#' @details See help for function \code{as.matrix} in native R
44
#' @param x.name the name of the input object to be coerced to class
55
#' matrix. Must be specified in inverted commas. But this argument is
66
#' usually specified directly by <x.name> argument of the clientside function
7-
#' {ds.asMatrix}
7+
#' \code{ds.asMatrix}
88
#' @return the object specified by the <newobj> argument (or its default name
99
#' <x.name>.mat) which is written to the serverside. For further
10-
#' details see help on the clientside function {ds.asMatrix}
10+
#' details see help on the clientside function \code{ds.asMatrix}
1111
#' @author Amadou Gaye, Paul Burton for DataSHIELD Development Team
1212
#' @export
1313
asMatrixDS <- function (x.name){

R/completeCasesDS.R

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
#' @title completeCasesDS: an assign function called by ds.completeCases
22
#' @description Identifies and strips out all rows of a data.frame,
33
#' matrix or vector that contain NAs.
4-
#' @details In the case of a data.frame or matrix, {completeCasesDS} identifies
4+
#' @details In the case of a data.frame or matrix, \code{completeCasesDS} identifies
55
#' all rows containing one or more NAs and deletes those
66
#' rows altogether. Any one variable with NA in a given row will lead
7-
#' to deletion of the whole row. In the case of a vector, {completeCasesDS}
7+
#' to deletion of the whole row. In the case of a vector, \code{completeCasesDS}
88
#' acts in an equivalent manner but there is no equivalent to a 'row'
99
#' and so it simply strips out all observations recorded as NA.
10-
#' {ds.completeCASES} is analogous to the {complete.cases} function
10+
#' \code{ds.completeCASES} is analogous to the \code{complete.cases} function
1111
#' in native R. Limited additional information can therefore be found
1212
#' under help("complete.cases") in native R.
1313
#' @param x1.transmit This argument determines the input data.frame,
1414
#' matrix or vector from which rows with NAs are to be stripped.
1515
#' The <x1.transmit> argument is fully specified by the <x1> argument
16-
#' of the {ds.completeCases} function.
16+
#' of the \code{ds.completeCases} function.
1717
#' @return a modified data.frame, matrix or vector from which
1818
#' all rows containing at least one NA have been deleted. This
1919
#' modified object is written to the serverside in each source.
@@ -24,7 +24,7 @@
2424
#' ds.completeCases also returns any studysideMessages that can help
2525
#' explain the error in creating
2626
#' the full output object. As well as appearing on the screen at run time,if you wish to
27-
#' see the relevant studysideMessages at a later date you can use the {ds.message}
27+
#' see the relevant studysideMessages at a later date you can use the \code{ds.message}
2828
#' function. If you type ds.message("newobj") it will print out the relevant
2929
#' studysideMessage from any datasource in which there was an error in creating <newobj>
3030
#' and a studysideMessage was saved. If there was no error and <newobj> was created

R/dataFrameSubsetDS2.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747
#' dataFrameSubsetDS2 (via ds.dataFrame()) also returns any studysideMessages
4848
#' that can explain the error in creating
4949
#' the full output object. As well as appearing on the screen at run time,if you wish to
50-
#' see the relevant studysideMessages at a later date you can use the {ds.message}
50+
#' see the relevant studysideMessages at a later date you can use the \code{ds.message}
5151
#' function. If you type ds.message("newobj") it will print out the relevant
5252
#' studysideMessage from any datasource in which there was an error in creating <newobj>
5353
#' and a studysideMessage was saved. If there was no error and <newobj> was created

R/lexisDS2.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ lexisDS2 <- function(datatext=NULL, intervalWidth, maxmaxtime, idCol, entryCol,
129129

130130

131131
#intervalWidth IS A SINGLE VALUE
132-
if(is.null(intervalWidth)||is.na(intervalWidth)||intervalWidth==0){
132+
if(any(is.null(intervalWidth))||any(is.na(intervalWidth))||any(intervalWidth==0)){
133133
return("A VALID NON-ZERO intervalWidth ARGUMENT MUST BE SPECIFIED")
134134
}
135135

R/lsDS.R

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,23 +2,23 @@
22
#' @title lists all objects on a serverside environment
33
#' @description creates a list of the names of all of the objects in
44
#' a specified serverside environment
5-
#' @details Serverside aggregate function {lsDS} called by clientside function
6-
#' {ds.ls}. When running analyses one may want to know the objects already generated. This
5+
#' @details Serverside aggregate function \code{lsDS} called by clientside function
6+
#' \code{ds.ls}. When running analyses one may want to know the objects already generated. This
77
#' request is not disclosive as it only returns the names of the objects and not their contents.
88
#' By default, objects in the current 'active analytic environment' (".GlobalEnv")
99
#' will be displayed. This
1010
#' is the environment that contains all of the objects that serverside DataSHIELD
1111
#' is using for the main analysis or has written out to the serverside during the process
1212
#' of managing or undertaking the analysis (variables, scalars, matrices, data.frames etc).
13-
#' For further details see help for {ds.ls} function and for native R function {ls}
13+
#' For further details see help for \code{ds.ls} function and for native R function \code{ls}
1414
#' @param search.filter either NULL or a character string (potentially including '*'
1515
#' wildcards) specifying required search criteria. This argument is
1616
#' fully specified by its corresponding argument in the clientside function.
1717
#' @param env.to.search integer (e.g. in a format such as '2' or '5L' format) specifying
1818
#' the position in the search path of the environment to be explored. This argument is
1919
#' fully specified by its corresponding argument in the clientside function.
2020
#' @return a list containing: (1) the name/details of the serverside R environment
21-
#' which {ds.ls} has searched; (2) a vector of character strings giving the names of
21+
#' which \code{ds.ls} has searched; (2) a vector of character strings giving the names of
2222
#' all objects meeting the naming criteria specified by the argument <search.filter> in this
2323
#' specified R serverside environment; (3) the nature of the search filter string as it was
2424
#' actually applied

R/matrixDS.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#' @title matrixDS assign function called by ds.matrix
22
#' @description Creates a matrix A on the serverside
3-
#' @details Similar to the {matrix()} function in native R. Creates a matrix
3+
#' @details Similar to the \code{matrix()} function in native R. Creates a matrix
44
#' with dimensions specified by <nrows.scalar> and <ncols.scalar> arguments
55
#' and assigns the values of all its elements based on the <mdata> argument
66
#' @param mdata.transmit specifies the elements of the matrix to be created. Fully

R/matrixDetDS1.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#' @description Calculates the determinant of a square matrix A and returns
33
#' the output to the clientside
44
#' @details Calculates the determinant of a square matrix (for additional
5-
#' information see help for {det} function in native R). This operation is only
5+
#' information see help for \code{det} function in native R). This operation is only
66
#' possible if the number of columns and rows of A are the same.
77
#' @param M1.name A character string specifying the name of the matrix for which
88
#' determinant to be calculated

0 commit comments

Comments
 (0)