Re: [Rd] Welcome to the R-devel mailing list

2007-09-19 Thread 马传香
2007/9/19, [EMAIL PROTECTED] [EMAIL PROTECTED]: Welcome to the R-devel@r-project.org mailing list! To post to this list, send your email to: r-devel@r-project.org General information about the mailing list is at: https://stat.ethz.ch/mailman/listinfo/r-devel If you ever want to

[Rd] How to test if R is running on a Mac

2007-09-19 Thread Gorjanc Gregor
Hi! Is there any way to test if R is running on a Mac? I usually use value of .Platform$OS.type for windows or unix, but Mac falls in the latter group. Thanks, Gregor __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel

Re: [Rd] How to test if R is running on a Mac

2007-09-19 Thread Oleg Sklyar
I had the same problem. The following line using either 'apple' or 'darwin' does the job for me (tested on many different Macs): length(grep(apple, tolower(Sys.getenv(R_PLATFORM != 0 On Wed, 2007-09-19 at 15:41 +0200, Gorjanc Gregor wrote: Hi! Is there any way to test if R is running

Re: [Rd] How to test if R is running on a Mac

2007-09-19 Thread Vladimir Eremeev
Gregor Gorjanc-2 wrote: Hi! Is there any way to test if R is running on a Mac? I usually use value of .Platform$OS.type for windows or unix, but Mac falls in the latter group. Thanks, Gregor What is in .Platform$path.sep? Windows has ;, unix has :. Mac? -- View this message in

Re: [Rd] How to test if R is running on a Mac

2007-09-19 Thread Vladimir Eremeev
Vladimir Eremeev wrote: Gregor Gorjanc-2 wrote: Hi! Is there any way to test if R is running on a Mac? I usually use value of .Platform$OS.type for windows or unix, but Mac falls in the latter group. Thanks, Gregor What is in .Platform$path.sep? Windows has ;, unix has :.

Re: [Rd] How to test if R is running on a Mac

2007-09-19 Thread Duncan Murdoch
On 9/19/2007 9:41 AM, Gorjanc Gregor wrote: Hi! Is there any way to test if R is running on a Mac? I usually use value of .Platform$OS.type for windows or unix, but Mac falls in the latter group. Remember to also look at .Platform$GUI: the GUI version behaves quite differently from

[Rd] building a package - shared library loading problem

2007-09-19 Thread Konrad Smolinski
Dear All, I am trying to write my first R package and I bump into loading shared library problem( working on Mac OS X 10.4.10 as well as Linux Ubuntu). I want to makes use of (incorporate) a shared library matchinglib.so in the package. Library was created via R CMD -SHLIB. Following 'Writing

[Rd] Best practices - R CMD check and vignettes

2007-09-19 Thread James MacDonald
Hi, I have a package that contains two vignettes that both use saved objects in the examples directory of the package. With previous versions of R I could have a code chunk in the vignette like this: echo=false= load(../examples/somedata.Rdata) @ followed by a code chunk like eval=false= foo

[Rd] delayedAssign

2007-09-19 Thread Gabor Grothendieck
The last two lines of example(delayedAssign) give this: e - (function(x, y = 1, z) environment())(1+2, y, {cat( HO! ); pi+2}) (le - as.list(e)) # evaluates the promises $x promise: 0x032b31f8 $y promise: 0x032b3230 $z promise: 0x032b3268 which contrary to the comment appears unevaluated. Is

Re: [Rd] building a package - shared library loading problem

2007-09-19 Thread Simon Urbanek
Konrad, for a package you should not be using R CMD SHLIB at all. It is used internally and for non-package compilation. If you have a proper source package, you just install it using R CMD INSTALL. To be precise, assuming you have your package and source code in the foo directory you can

Re: [Rd] Best practices - R CMD check and vignettes

2007-09-19 Thread James W. MacDonald
Thanks, Max. Right after sending that email I was frantically searching for the 'Retract' button on my mailer, but evidently there isn't one ;-D. Anyway, I'm not sure the entire package is installed during either R CMD build or R CMD check, so I am not sure that will work. My ill-advised idea

Re: [Rd] R-2.6.0 for Windows, semi-transparent colours and layout()

2007-09-19 Thread Henric Nilsson (Private)
Prof Ripley, Quoting Prof Brian Ripley [EMAIL PROTECTED]: On Sat, 15 Sep 2007, Henric Nilsson (Public) wrote: Hi, The added support for semi-transparent colours in `windows' under R-2.6.0 for Windows is much appreciated. However, I've discovered that issuing a `layout' (or `par' with

Re: [Rd] How to test if R is running on a Mac

2007-09-19 Thread Hin-Tak Leung
On linux boxes, version$os and R.version$os is 'linux-gnu'. I assume that it would be 'darwin-apple' on Mac's? Henrik Bengtsson wrote: isApple - function(...) { isApple - FALSE; tryCatch({ ans - readline(Do you see an Apple key on the keyboard you are typing on? yes/no);

Re: [Rd] delayedAssign

2007-09-19 Thread Gabor Grothendieck
Also note that earlier in the same example we have: msg - old delayedAssign(x, msg) msg - new! x #- new! [1] new! substitute(x) #- msg x R.version.string # Vista [1] R version 2.6.0 alpha (2007-09-06 r42791) That is substitute(x) gives x, not msg. On 9/19/07, Gabor Grothendieck [EMAIL

[Rd] copying promise

2007-09-19 Thread Gabor Grothendieck
1. Is there some way to copy a promise so that the copy has the same expression in its promise as the original. In the following we y is a promise that we want to copy to z. We want z to be a promise based on the expression x since y is a promise based on the expression x. Thus the answer to

[Rd] Sweave vignettes and bitmap on windows

2007-09-19 Thread Martin Morgan
During vignette generation on Windows, Sweave seems to clean up before all graphics files are completely processed. For instance, if tmp.Rnw is: \documentclass[12pt]{article} \begin{document} = bitmap(afile.png) plot(1:100) dev.off() @ \end{document} Then: C:\R\tmpR CMD Sweave tmp.Rnw Writing

[Rd] packages MANOR, qvalue, and tkWidgets fail install on Fedora 7 with latest R-beta build

2007-09-19 Thread Mark W Kimpel
Had some packages fail install so I updated to today's R-beta release. On updating packages the following packages still fail. sessionInfo follows. Mark Warning messages: 1: In install.packages(update[instlib == l, Package], l, contriburl = contriburl, : installation of package 'MANOR' had

Re: [Rd] packages MANOR, qvalue, and tkWidgets fail install on Fedora 7 with latest R-beta build

2007-09-19 Thread Martin Morgan
Hi Mark -- sessionInfo and the warning messages are not enough here. Try to install one of the failing packages and provide the complete transcript of the process. Consider sending this to the Bioconductor mailing lists (bioc-devel, in particular, since these packages are in the development

[Rd] S4 objects in data frames?

2007-09-19 Thread Byron Ellis
Is there any way to get S4 objects into a data frame and have the resulting data frame actually be printable? After a good deal of work I managed to convert an S4 objects that holds several other objects into a data.frame object using a custom as.data.frame method, but I have been unable to