Description Usage Arguments Examples
Extracts the complete cases, also known as listwise deletion.
cc(x)
is similar to
na.omit(x)
, but returns an object of the same class
as the input data. Dimensions are not dropped.
1 | ds.mice.cc(varname = NULL, x = NULL, checks = TRUE, datasources = NULL)
|
varname |
A character object that will be the name of the variable to which the result of the function will be assigned on the server-side |
x |
An |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | # In this example, we assume that the Opal server to which we are connecting,
# has a table that contains the 'boys' data from the original mice package.
library(dsBaseClient)
library(dsMiceClient)
# Build login information
server <- c("server_name")
url <- c("opal_url")
user <- "username"
password <- "password"
table <- c("project_name.table_name")
logindata <- data.frame(server,url,user,password,table)
# Login and assign the 'boys' dataset to varable 'D' on the server-side
opals<-datashield.login(logins=logindata, assign=TRUE)
# Check dimension of D
ds.dim('D')
# Extract complete cases from D and assign result to D2
ds.mice.cc("D2", "D")
# Check dimension of D2 (should be equal to or smaller than dim of D)
ds.dim('D2')
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.