[Rd] unique.default() drops names (PR#9130)

2006-08-07 Thread Gregor . Gorjanc
Hello! unique on a vector or list drops names, while it does not in case of data.frames and matrix - rownames and colnames here, but they are intuitively the same as names. The following code shows this effect: vecTest - c(A, D, B, D, A) names(vecTest) - paste(name, vecTest, sep=)

Re: [Rd] Can't make sort generic in quantile (S3)

2006-08-07 Thread Prof Brian Ripley
It's a namepsace issue: any function in a namespace will see the definition in base rather than yours. quantile() is already generic, so why do you want to make sort() generic? In particular, the function you show is not implementing much of the power of sort (and in this case in particular not

[Rd] Documentation for S3 generics

2006-08-07 Thread Gorjanc Gregor
Hello! Say I have myMethod - function(x, ...) UseMethod(myMethod) myMethod.classA - function(x, ...) ... myMethod.classB - function(x, ...) ... myMethod.classC - function(x, arg2, ...) ... and I would like to properly document these as generics. Then I have to use in usage section

Re: [Rd] Documentation for S3 generics

2006-08-07 Thread Martin Maechler
Gorjanc == Gorjanc Gregor [EMAIL PROTECTED] on Mon, 7 Aug 2006 11:59:31 +0200 writes: Gorjanc Hello! Gorjanc Say I have Gorjanc myMethod - function(x, ...) Gorjanc UseMethod(myMethod) Gorjanc myMethod.classA - function(x, ...) Gorjanc ... Gorjanc

Re: [Rd] Documentation for S3 generics

2006-08-07 Thread Gorjanc Gregor
From: Martin Maechler [mailto:[EMAIL PROTECTED] Gorjanc == Gorjanc Gregor [EMAIL PROTECTED] on Mon, 7 Aug 2006 11:59:31 +0200 writes: Gorjanc Hello! Gorjanc Say I have Gorjanc myMethod - function(x, ...) Gorjanc UseMethod(myMethod) Gorjanc myMethod.classA -

Re: [Rd] Documentation for S3 generics

2006-08-07 Thread Gabor Grothendieck
Exporting a method allows the user to access the method directly as opposed to calling the generic. For example, try: methods(plot) The methods listed with stars are not exported although they are still available through the generic. For example: plot(ts(1:10)) plot.ts(ts(1:10))

[Rd] Pb with contrib.url() (PR#9131)

2006-08-07 Thread hpages
Hi lists, Recently I needed to download a few R packages for Unix, Windows and Mac OS X. The idea was to put them all together on a USB key in order to be able to install them on systems without network connection. It worked fine for the src and win.binary packages but I had the following

Re: [Rd] Customized Makefiles (C++ and R)

2006-08-07 Thread Selwyn-Lloyd McPherson
If I do R CMD CHECK, R uses the makefile that came with the source files to create the .o files but does not create the .so file (I still get the cp: *.so: No such file or directory error). I tried playing around with that makefile but to no avail. I can use R CMD SHLIB to create the .so

Re: [Rd] Documentation for S3 generics

2006-08-07 Thread Gorjanc Gregor
Thank you Gabor for this explanation. No I get it! However, I am still not clear on documenting generic methods in my case. I could document only the methods that have more arguments than simple ones, in my case classX, but then the output in help page will only be for classC and I have to mention

[Rd] error: Broken pipe cat ${in} (PR#9132)

2006-08-07 Thread asgoyal
Full_Name: ashutosh goyal Version: 1.9.1 OS: Linux Submission from: (NULL) (192.147.57.6) I am calling a R script from shell prompt using Rcmd BATCH script.R option where I am seeing this error. Any idea what can be the reason?? __

[Rd] Typo in R-exts.texi and suggestion for tests

2006-08-07 Thread Gorjanc Gregor
svn diff against r-devel Index: R/doc/manual/R-exts.texi === --- R/doc/manual/R-exts.texi(revision 38809) +++ R/doc/manual/R-exts.texi(working copy) @@ -563,7 +563,7 @@ @file{.Rin} file containing code which in turn creates

Re: [Rd] Can't make sort generic in quantile (S3)

2006-08-07 Thread miguel manese
Thanks for the fix. I'm guessing the rules are: a. a non S3 method is bound to the global env, and will see the def'n of an S3-ized method (e.g. I made is.list() generic and lapply, w/c is not generic, gets the S3-ized is.list) b. an S3 method implementation is bound to the namespace it was

[Rd] StringFromInteger made private in r38652

2006-08-07 Thread Seth Falcon
Hi, In commit 38652, StringFromInteger (among others) was removed from R's public API. I've just come across a Bioconductor package, RdbiPgSql, that uses this function. Is there an alternative that is in the public API? If not, it would be nice to be able to reuse these sorts of helper

Re: [Rd] Documentation for S3 generics

2006-08-07 Thread Gabor Grothendieck
If you are writing the generic then you could use the same .Rd file to list and document the methods or just mention them in the text. If the generic is not part of your package you could use the -class.Rd file to do that or you could have separate .Rd pages for specific methods. I don't think

[Rd] [R] C Entry Points

2006-08-07 Thread Gregory Wall
Hi Everyone: I'm getting this error when I try to call a C routine from within an R package: Error in .C(testC, as.integer(length(x)), ans = double(1), PACKAGE = mypkg) : C entry point testC not in DLL for package mypkg here are some useful outputs: nm mypkg.so | grep testC

Re: [Rd] [R] C Entry Points

2006-08-07 Thread Seth Falcon
Gregory Wall [EMAIL PROTECTED] writes: Hi Everyone: I'm getting this error when I try to call a C routine from within an R package: Error in .C(testC, as.integer(length(x)), ans = double(1), PACKAGE = mypkg) : C entry point testC not in DLL for package mypkg here are some useful outputs:

Re: [Rd] Pb with contrib.url() (PR#9131)

2006-08-07 Thread Simon Urbanek
Herve, On Aug 7, 2006, at 11:34 AM, [EMAIL PROTECTED] wrote: Recently I needed to download a few R packages for Unix, Windows and Mac OS X. The idea was to put them all together on a USB key in order to be able to install them on systems without network connection. It worked fine for