ds.dim {dsBaseClient} | R Documentation |
this function is similar to R function dim
ds.dim(x = NULL, type = "split", datasources = NULL)
x |
a character, the name of R table object, for example a matrix, array or data frame |
type |
a character which represents the type of
analysis to carry out. If |
datasources |
a list of opal object(s) obtained
after login in to opal servers; these objects hold also
the data assign to R, as |
the function returns the unpooled or pooled dimension of the object by summing up the individual dimensions returned from each study or the dimension of the object in each study. Unlike the other DataSHIELD function the default behaviour is to output the dimension of each study separately.
for an array, NULL
or a vector of mode
integer
Gaye, A.; Isaeva, J.
ds.dataframe to generate a table of type dataframe.
ds.changeRefGroup to change the reference level of a factor.
ds.colnames to obtain the column names of a matrix or a data frame
ds.asMatrix to coerce an object into a matrix type.
ds.length to obtain the size of a vector.
{ # load that contains the login details data(logindata) # login and assign all the stored variables. opals <- datashield.login(logins=logindata,assign=TRUE) # Example 1: Get the dimension of the assigned datasets in each study ds.dim(x='D') # Example 2: Get the pooled dimension of the assigned datasets ds.dim(x='D', type='combine') # Example 2: Input has to be either matrix, data frame or an array # In the below example, the inpout is a vector so it will not work. ## Not run: ds.dim(x='D$LAB_TSC') # clear the Datashield R sessions and logout datashield.logout(opals) }