[R] detect filetype (as in unix 'file')

Jeroen Ooms jeroenooms at gmail.com
Tue Apr 5 21:30:16 CEST 2011


> No, but what is wrong with using system()?

The application is running in a very sandboxed environment and might
not have permission to execute 'file'.

> 'file' is large and complex because it tries to be comprehensive (but it
> still does not know about some common systems, e.g. 64-bit Windows
> binaries).  There simply is no point in replicating that in R: which is why
> we chose rather to port 'file' to Windows and provide in in Rools.

Alright that makes sense, thanks.



More information about the R-help mailing list