create subdatasets
# Clean environment
closeAllConnections()
rm(list=ls())
# Set enviroment
setwd("~/your working directory")
# Load packages
library(bnpa)
# Load data sets from package
data1<-dataQualiN
###################################################################################
# create.subdatasets.R - Creates sub data sets.
###################################################################################
# Load data.work
data.to.work <- data1
# Set variables
variables <- c( "A","S","L","E","D")
# Set the new dataset name
dataset.name <- "data.work.new"
# Creates the subdataset
create.subdatasets(data.to.work, variables, dataset.name)
###################################################################################
RESULTS:
###################################################################################
The original dataset:
The new dataset: