If you have used R’s read.csv
function, you will inevitably use the stringsAsFactors=FALSE
option. Roger Peng offers a brief history into why the default for stringAsFactors option is TRUE.
Alternatively, you can use the read_csv
function from the readr package by Hadley Wickham, which does not automatically convert characters to factors.