.Platform adalah daftar dengan beberapa detail platform tempat R dibangun. Ini menyediakan sarana untuk menulis kode R portabel OS.
.Platform
# NOT RUN {
## Note: this can be done in a system-independent way by dir.exists()
if(.Platform$OS.type == "unix") {
system.test <- function(...) system(paste("test", ...)) == 0L
dir.exists2 <- function(dir)
sapply(dir, function(d) system.test("-d", d))
dir.exists2(c(R.home(), "/tmp", "~", "/NO")) # > T T T F
}
# }