validate (version 0.9.3)

indicator: Define indicators for data

Description

This feature is currently experimental and may change in future versions

Usage

indicator(..., .file, .data)

Arguments

...

A comma-separated list of indicator definitions

.file

(optional) A character vector of file locations

Details

indicator

See Also

syntax

Examples

Run this code
# NOT RUN {
# create an indicator for the number of missing x in data set


I <- indicator( 
 sum(is.na(.))               # number of missing variables
 , sum(is.na(.[c("x","y")])) # number of missing x and y
 , mean(is.na(.))            # fraction of missing variables
 , sum(x)
 , mean(x)
) 

dat <- data.frame(x=1:2, y=c(NA,1))
C <- confront(dat, I)
values(C)
# }

Run the code above in your browser using DataCamp Workspace