I'm trying to convert all the columns that appear as logical when importing a csv to characters.
These code bellow works if I call every column, but I have over 200 columns so its not feasible.
library(stringi)
library(readr)
library(dplyr)
df <- read_csv("~/dataverified.csv",
col_types = cols(
Innovation = col_character(),
Tech = col_character(),
Music = col_character()))
Here is sample of the summary () for one column and bellow is the desire output
e.g summary of input
Innovation
Mode:logical
TRUE:403
NA's 45600
e.g summary of desire output for every column
Innovation
Length: 45900
Class:character
Mode:character