I am using R.3.3.1. in RStudio 0.99.903 on a work PC.
I have a tab-separated file that i'm trying to read in with fread. Unfortunately some of the rows end with double-tab while others don't.
Here's the first few lines of my data:
[1] "1054434\t01-01-2015\t-1\tAMOUNT OWN MUSIC\t12\t\t"
[2] "1054434\t01-01-2015\t-1\tDVDS\t2\t"
[3] "1054434\t01-01-2015\t-1\tINIT TV\t2\t\t"
[4] "1054434\t01-01-2015\t-1\tINIT2\t4\t\t"
[5] "1054434\t01-01-2015\t-1\tIntro_other_TV\t2\t\t"
I thought i could get around this problem using the option fill=TRUE but i get this error message:
test<-fread(filenames[1], header = FALSE, fill = TRUE)
Error in fread(filenames[1], header = FALSE, fill = TRUE) :
unused argument (fill = TRUE)
I don't understand why fill doesn't work as it's definitely a valid option according to the help file...
I am using data.table 1.9.6. from CRAN as i get this error message when i try to install the github version:
* installing *source* package 'data.table' ...
** libs
*** arch - i386
Warning: running command 'make -f "Makevars" -f "D:/R- 33~1.1/etc/i386/Makeconf" -f "D:/R-33~1.1/share/make/winshlib.mk" SHLIB="data.table.dll" OBJECTS="assign.o bmerge.o chmatch.o dogroups.o fastmean.o fcast.o fmelt.o forder.o frank.o fread.o fsort.o fwrite.o gsumm.o ijoin.o init.o openmp-utils.o quickselect.o rbindlist.o reorder.o shift.o subset.o transpose.o uniqlist.o vecseq.o wrappers.o"' had status 127
ERROR: compilation failed for package 'data.table'
* removing 'D:/R-3.3.1/library/data.table'
Warning in install.packages :
running command '"D:/R-33~1.1/bin/x64/R" CMD INSTALL -l "D:\R-3.3.1\library" C:\Users\swiftc47\AppData\Local\Temp\RtmpeYBevK/downloaded_packages/data.table_1.9.7.tar.gz' had status 1
Warning in install.packages :
installation of package ‘data.table’ had non-zero exit status