how to find type of columns dataframe in r code example
Example: r type of all columns
sapply(my.data, class)
y x1 x2 X3
"numeric" "integer" "logical" "factor"
sapply(my.data, class)
y x1 x2 X3
"numeric" "integer" "logical" "factor"