I noticed that in
https://svn.r-project.org/R/trunk/src/library/stats/R/loess.R
that we are now calling R_loess_raw, R_lowesw, R_lowesp, etc. I'm
interested to know what is the benefit/reason for the 'R_', as I am
unfamiliar with this prefix and do not see it mentioned in 'Writing R
Extensions
That's because you are passing the argument twice. Try this:
> foo1 <- function(x, ...)
+ {
+ L <- list(...)
+ if (is.null(L$decreasing)) L$decreasing <- TRUE
+ do.call(order, c(list(x), L))
+ }
>
> foo1(c(5, 2, 3, 4), decreasing=FALSE)
[1] 2 3 4 1
On 7/1/06, Gregor Gorjanc <[EMAIL PROTECTED]
Hi,
Gabor Grothendieck wrote:
> Try this:
>
>> f <- function(...) if (!is.null(list(...)$arg1)) cat("arg1 found\n")
>> else cat("arg1 not found\n")
>> f(arg1 = 3)
> arg1 found
>> f(arg2 = 3)
> arg1 not found
Actually it is not OK. Bellow is simplified example that shows, what I
would like to do:
Gabor Grothendieck wrote:
> Try this:
>
>> f <- function(...) if (!is.null(list(...)$arg1)) cat("arg1 found\n")
>> else cat("arg1 not found\n")
>> f(arg1 = 3)
> arg1 found
>> f(arg2 = 3)
> arg1 not found
Thanks!
Use of list(...) really helps me here.
> On 7/1/06, Gregor Gorjanc <[EMAIL PROTECTE
Try this:
> f <- function(...) if (!is.null(list(...)$arg1)) cat("arg1 found\n") else
> cat("arg1 not found\n")
> f(arg1 = 3)
arg1 found
> f(arg2 = 3)
arg1 not found
On 7/1/06, Gregor Gorjanc <[EMAIL PROTECTED]> wrote:
> Hello!
>
> Say I have a function foo1, which has argument ... to pass vario
Hello!
Say I have a function foo1, which has argument ... to pass various
arguments to foo2 i.e.
foo1 <- function(x, ...)
{
foo2(x, ...)
}
Say that foo2 accepts argument arg1 and I would like to do the following:
- if foo1 is called as foo1(x) then I would like to assign some value to
arg1 ins
Full_Name: Long Qu
Version: 2.3.1
OS: Windows XP
Submission from: (NULL) (64.113.93.235)
The QQ-plot of two versions of simulating noncentral F-distributed random
numbers has quite different scales:
> qqplot(rf(1000,2,15,3),qf(runif(1000),2,15,3))
The rf() function reads:
> rf
function (n, df1,
Full_Name: Jori Mäntysalo
Version: 2.3.1
OS: Linux, GNU/Debian stable
Submission from: (NULL) (81.197.171.182)
I said
./configure --with-readline=no --with-x=no
make
make install
and everything works except that /usr/local/lib/R/etc/ldpaths was not readable
as normal user.
_
Thank you Bill,
particularly for not only reporting the bug but also diagnose
and patch it.
I've committed the fix for both R-devel and R-patched.
With regards,
Martin
>> If an Rd file has only one keyword entry then
>> the Splus sgm file made with Rdconv --type=SSgm
>> has no keyword entries.