Re: [R] the name of the current running script.r

2008-08-14 Thread Henrique Dallazuanna
maybe you can do something about like this: #height.r script beg SourceFileDir <- "f:/documents/data & fits/THz Imaging Lab/r scripts" SourceFileName <- "height.r" source(file.path(SourceFileDir, SourceFileName)) # height.r script end savehistory() FileNameSourced <- gsub("source\\(|\\)|\"", "",

[R] the name of the current running script.r

2008-08-14 Thread Zroutik Zroutik
Dear R users, is there a hack how to get the filename of the current script.r sourced/ran? My issue: I have a couple of scripts which were optimised and are placed in tens of directories. (I have a height.r script in 30 directories, a lines.r script in 25 directories and another flow.r script in