i am trying to load a csv file containing : 517 000 line, and only 20 variables, i am using read.table.ffdf, and it gives the error :
Error in ff(initdata = initdata, length = length, levels = levels, ordered = ordered, :
write error
i used the line :
dépenses<- read.table.ffdf(
file="COVID-19_Expenditures_Report.csv",
sep=",",
VERBOSE=FALSE,
header=TRUE,
colClasses=NA
)
i have seen similar questions with the same error due to the high number of variables, but mine isn't due to that, as i have previously used the same function to read more variables than 20, successfully.
Try data.table with fread, it loads in your data very fast without any issues.
library(data.table)
depenses <- fread(file="COVID-19_Expenditures_Report.csv", sep=",", header = T)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.