今天要将句子库导出,方便用filelocator查询,但
write.table
实在低消,需要将character分割,而且分割得太大的话总是内存不够。data.table
中的fwrite()
能够苗存,太牛了。
# library(data.table)
db <- list(db)
setDT(db)
fwrite(db, "./result/sent.txt", quote = F, row.names= F)
from: https://stackoverflow.com/questions/37068537/exporting-large-character-vector-as-csv-file-in-r
网友评论