I want to perform univariate assessment on a dataset. I came up with the code below:
library(dplyr)
data <- fnlDat_Train
data$response <- as.character(data$response)
data$Y <- sample(0:1,size=nrow(data),replace=TRUE)
univariate_list <- univariate(base = data,target = "Y",threshold = 0.95)
univariate_list$univar_table
univariate_list$num_var_name
univariate_list$char_var_name
univariate_list$sparse_var_name
I got an error message
Error in univariate(base = data, target = "Y", threshold = 0.95) : could not find function "univariate"
Here is my data structure
I need to do a scatterplot of a dataset that contains character, integer and numeric attributes.
Here is my code:
fdn <- read.table("final-data-train.csv",sep=",",header=TRUE)
pairs(~dtj+qh+sci+bw+is,data=fdn,row1attop=FALSE,subset=response,main="Fund Data")
Data Structure:
str(fnlDat_Train)
'data.frame': 30994 obs. of 19 variables:
$ response: chr "N" "N" "Y" "Y" ...
$ id : int 165931 241964 387089 433922 175120 353214 458159 512275 310008 91571 ...
$ wc : chr "d" "b" "b" "b" ...
$ zwp : chr "R" "S" "O" "Q" ...
$ wi : chr "gnq" "gmz" "gmz" "gmz" ...
$ dtj : num 3.32 0 3.46 3.32 3.74 ...
$ bnf : chr "J" "K" "J" "L" ...
$ qh : num 1.62 1.47 2.01 1.92 1.74 ...
$ ent : chr "A" "A" "A" "A" ...
$ sci : num 1.36 1.42 1.43 1.41 1.36 ...
$ ypz : int 11 11 14 10 1 0 1 1 14 1 ...
$ bw : num 0.316 0.447 0.447 0.387 0.316 ...
$ tdt : chr "kc" "sm" "zp" "sm" ...
$ sb : chr "s2" "s2" "s2" "s2" ...
$ ox : chr "bf" "fy" "ix" "bf" ...
$ xt : chr "fcc" "ntb" "ntb" "ntb" ...
$ np : chr "j" "j" "j" "k" ...
$ ku : chr "y" "v" "u" "x" ...
$ is : num 0.241 3.762 2.5 2.477 4.171 ..
How can I fix this error?