Robert I've been looking through my "R -- S compatibility" functions which may mostly disappear in R 0.60. In fact, it seems already that most of the things I'm trying to do are for operating system differences rather than R/S differences. The main problem I am having is that version$os gives more detail then I usually need, but it is not very convenient for determining simply if the operating system is Unix. Perhaps you could suggest a better version of the OStype function below. Thanks Paul Gilbert ___________ OStype <- function() {if (version$os == "MS Windows") return(version$os) if (version$os == "Mac") return(version$os) # needs to be checked else return ("Unix") # not a very satisfactory test } is.MSwindows <- function(){OStype() == "MS Windows"} is.unix <- function(){OStype() == "Unix" } =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
>>>>> Paul Gilbert writes:> Robert > I've been looking through my "R -- S compatibility" functions which may > mostly disappear in R 0.60. In fact, it seems already that most of the > things I'm trying to do are for operating system differences rather than > R/S differences. The main problem I am having is that version$os gives > more detail then I usually need, but it is not very convenient for > determining simply if the operating system is Unix. Perhaps you could > suggest a better version of the OStype function below.> Thanks > Paul Gilbert > ___________> OStype <- function() > {if (version$os == "MS Windows") return(version$os) > if (version$os == "Mac") return(version$os) # needs to be checked > else return ("Unix") # not a very satisfactory test > }Isn't this what machine() does? -k =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Seemingly Similar Threads
- isolating R/S and operating system differences
- R-alpha: compatibility functions
- Error: (28, ''No space left on device, while writing /vm/ba5fda47-f44a-2f44-b164-d2b1290d0d60/image/ostype : linux'')
- Error: (28, ''No space left on device, while writing /vm/ba5fda47-f44a-2f44-b164-d2b1290d0d60/image/ostype : linux'')
- R-alpha: system() ok -- is.R() function