[R-pkg-devel] data function from utils package

Mike Mehan mmehan at gmail.com
Tue Aug 16 21:28:50 CEST 2016


Hi,
I'm having trouble loading a csv file from my package data directory using
the data() function. We have an external file that gets updated every month
or so that we would like to include as data in our package. We are able to
import it using the data function when it is saved as an R Data file but
when we save it as a csv file it fails. I checked the help for data and it
says that it supports csv files but it says that it calls read.table with
the separator as a semi-colon instead of a comma. I checked the source code
and it also uses a semi-colon. Is this a bug? I would be really nice to be
able to use csv files since we refresh this file fairly often and I'd
rather not have to save it as an R data file each time. We also got it
working with system.file but using data() is much cleaner. Any suggestions?
Thanks,
Mike

	[[alternative HTML version deleted]]



More information about the R-package-devel mailing list