# NOT RUN {
# Load toy data set
require(data.table)
data(messy_adult)
# Reduce set size to save time (you can run it on full set)
messy_adult = messy_adult[1:100, ]
# Check for included columns
whichAreIncluded(messy_adult)
# Return columns that are also constant, double and bijection
# Let's add a truly just included column
messy_adult$are50OrMore <- messy_adult$age > 50
whichAreIncluded(messy_adult[, .(age, are50OrMore)])
# As one can, see this column that doesn't have additional info than age is spotted.
# But you should be careful, if there is a column id, every column will be dropped:
messy_adult$id = 1:nrow(messy_adult) # build id
whichAreIncluded(messy_adult)
# }
Run the code above in your browser using DataLab