[R] How to know created time of object in R?
Tony Plate
tplate at acm.org
Thu Nov 29 06:18:30 CET 2007
The trackObjs package will do this, at the level of objects in an environment.
E.g., from the docs:
> library(trackObjs)
> track.start("tmp1")
> x <- 123 # Not yet tracked
> track(x) # Variable 'x' is now tracked
> track(y <- matrix(1:6, ncol=2)) # 'y' is assigned & tracked
> z1 <- list("a", "b", "c")
> z2 <- Sys.time()
> track(list=c("z1", "z2")) # Track a bunch of variables
> track.summary(size=F) # See a summary of tracked vars
class mode extent length modified TA TW
x numeric numeric [1] 1 2007-09-07 08:50:58 0 1
y matrix numeric [3x2] 6 2007-09-07 08:50:58 0 1
z1 list list [[3]] 3 2007-09-07 08:50:58 0 1
z2 POSIXt,POSIXct numeric [1] 1 2007-09-07 08:50:58 0 1
> # (TA="total accesses", TW="total writes")
(creation time is tracked too, but not displayed with default settings)
For more info, look in the trackObjs package.
-- Tony Plate
Dong-hyun Oh wrote:
> Dear UseRs,
>
> I would like to know the created time and date of specific object.
> Is there any function for it?
>
> Thank you in advance.
>
>
> Sincerely,
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
More information about the R-help
mailing list