[R] list.files() error message: 'translateCharUTF8' must be called on a CHARSXP

MacQueen, Don macqueen1 at llnl.gov
Tue Feb 1 01:46:44 CET 2011


I'm using list.files() on my home directory, like this:

   crnt.files <- list.files(dir.to.check, full.names=TRUE, all.files=TRUE,
recursive=TRUE)

With dir.to.check set to the full path to my home directory.

After a while I get:

Error in list.files(dir.to.check, full.names = TRUE, all.files = TRUE,  :
  'translateCharUTF8' must be called on a CHARSXP

This happens on one of my two machines, not the other.
Presumably there is a "file" somewhere in my home directory that, well,
isn't a file?
Or maybe has some strange character in its file name? That maybe isn't
valid in my LOCALE?

I would appreciate some advice on how to find this "file" so I can get rid
of it, or rename it, or something.

Also, does this message possibly represent a problem that the R developers
should pay attention to? I'm not sure.

Thanks
-Don


> sessionInfo()
R version 2.12.1 (2010-12-16)
Platform: x86_64-apple-darwin9.8.0/x86_64 (64-bit)

locale:
[1] C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base


-- 
Don MacQueen
Environmental Protection Department
Lawrence Livermore National Laboratory
925 423-1062



More information about the R-help mailing list