[R] file 'attributes'

Romain Francois francoisromain at free.fr
Sun Feb 6 20:15:53 CET 2005


Le 06.02.2005 15:35, Adrian Dusa a écrit :

>Liaw, Andy <andy_liaw <at> merck.com> writes:
>
>  
>
>>file.info() should help with some of those items.
>>
>>Andy
>>
>>    
>>
>>>From: Adrian Dusa
>>>
>>>Dear R-list,
>>>
>>>I have many files on many CDs (probably same as many of you) 
>>>and I would like 
>>>to create a database containing only a few columns:
>>>    - the name of the file
>>>    - its extension
>>>    - space occupied
>>>    - date when it was created
>>>    - its path
>>>    - CD number (this should be typed in manually)
>>>
>>>Is it possible to read a CD/structure of folders in such a way?
>>>Thank you for any suggestion,
>>>Adrian
>>>
>>>-- 
>>>Adrian Dusa
>>>Romanian Social Data Archive
>>>1, Schitu Magureanu Bd.
>>>Bucharest sector 5
>>>Romania
>>>Tel./Fax: +40 21 3126618 \
>>>              +40 21 3120210 / int.101
>>>
>>>      
>>>
>
>
>Brilliant, Andy. This is exactly what I needed. Now, if I could find a way to
>scan a structure of folders, I could store the information about every file in
>every folder in a table or a database...
>
>Using ?file.info, I found another bunch of useful functions, like file.path,
>list.files etc. It looks very promising.
>
>I know there is a command in Linux called 'file', which determines the file type
> (a substitute for the extension). I wonder if I could use that command via R.
>
>  
>
Within a R session

system("file")


Take a look at ?system

Romain.

>Thanks again,
>Adrian
>
>  
>
-- 
Romain FRANCOIS : francoisromain at free.fr
page web : http://addictedtor.free.fr/  (en construction)
06 18 39 14 69 / 01 46 80 65 60
_______________________________________________________
Etudiant en 3eme année
Institut de Statistique de l'Université de Paris (ISUP)
Filière Industrie et Services
http://www.isup.cicrp.jussieu.fr/




More information about the R-help mailing list