[R-SIG-Mac] File creation date

Kasper Daniel Hansen khansen at stat.berkeley.edu
Thu Oct 30 18:13:18 CET 2008


Loren, the easiest solution to your problem is to save objects in  
individual files, like

save(BigComputation, file = "BigComputation.rda")

that way you just have one object in each file and can use the file  
time stamp.

Using attributes are of course another approach.

Kasper

On Oct 30, 2008, at 9:57 , Loren Engrav wrote:

> Thank you
>
> That is too bad as date time of work is important
>
> But, going forward, maybe I can learn how to set the date time in the
> objects attributes when it is important
>
> Like I found a discussion on this topic from 2004 which suggests
> attr(obj, "timestamp") <- Sys.time()
> And then
> attr(obj, "timestamp")
>
> So I tried
> attr(obj, "datetime") <- date()
> Then
> attr(obj,"datetime")
>
> And it works so I can do that
>
> But then as I read the ref manual,
> file.info tries to show mtime, ctime and atime
> But I guess that does not apply to objects within a workspace
>
>
>> From: Simon Urbanek <simon.urbanek at r-project.org>
>> Date: Wed, 29 Oct 2008 12:08:53 -0400
>> To: Loren Engrav <engrav at u.washington.edu>
>> Cc: "r-sig-mac at stat.math.ethz.ch" <r-sig-mac at stat.math.ethz.ch>
>> Subject: Re: [R-SIG-Mac] File creation date
>>
>>
>> On Oct 28, 2008, at 19:03 , Loren Engrav wrote:
>>
>>> Sorry my email was unclear
>>> I am looking at files within a saved R workspace
>>>
>>> The date of the workspace file is 3/18/2007 but I don't think all of
>>> the
>>> files were created on that date as I think I used the workspace over
>>> some
>>> period of time
>>>
>>> So I would like the creation date of the files WITHIN the workspace
>>>
>>
>> There is no file *within* the workspace. The workspace *is* one file
>> of serialized R objects and they themselves don't have any timestamp
>> associated with them. So all you can find out is when you last saved
>> (or accessed) the workspace, that's all.
>>
>> Cheers,
>> S
>>
>>
>>>> From: Steve Lianoglou <mailinglist.honeypot at gmail.com>
>>>> Date: Tue, 28 Oct 2008 18:48:34 -0400
>>>> To: Loren Engrav <engrav at u.washington.edu>
>>>> Cc: "r-sig-mac at stat.math.ethz.ch" <r-sig-mac at stat.math.ethz.ch>
>>>> Subject: Re: [R-SIG-Mac] File creation date
>>>>
>>>> Hi,
>>>>
>>>> On Oct 28, 2008, at 6:00 PM, Loren Engrav wrote:
>>>>
>>>>> Ok, I give up
>>>>>
>>>>> I am exploring some workspace files created long long ago
>>>>> And need the creation date of some of the files
>>>>>
>>>>> I try ls() but cannot see the parameters to show creation date
>>>>> I try file.info and get NA
>>>>> How do I get creation date to show
>>>>
>>>> One way is to navigate to the file via the Finder, select it, and  
>>>> hit
>>>> Cmd-I (File > Get Info)
>>>>
>>>> You'll find what you're looking for in the "General" section.
>>>>
>>>> HTH,
>>>> -steve
>>>>
>>>> --
>>>> Steve Lianoglou
>>>> Graduate Student: Physiology, Biophysics and Systems Biology
>>>> Weill Medical College of Cornell University
>>>>
>>>> http://cbio.mskcc.org/~lianos
>>>>
>>>>
>>>>
>>>
>>> _______________________________________________
>>> R-SIG-Mac mailing list
>>> R-SIG-Mac at stat.math.ethz.ch
>>> https://stat.ethz.ch/mailman/listinfo/r-sig-mac
>>>
>>>
>>
>
> _______________________________________________
> R-SIG-Mac mailing list
> R-SIG-Mac at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/r-sig-mac



More information about the R-SIG-Mac mailing list