s-news
[Top] [All Lists]

Re: sapply question

To: <s-news@lists.biostat.wustl.edu>
Subject: Re: sapply question
From: "Chushu Gu" <chushugu@hotmail.com>
Date: Thu, 22 Jan 2004 20:48:54 -0500
Hi all,
 
I got a function has the following signature
 
outer.boot.func(10, 399, "cb.bootind.399.10",T)
 
What I want to do is to execute 91 times by changing the first parameter and get back a result vector.
Here is my code which is not working, could anyone give me a hand?
 
test <- list(10:100,339,"cb.bootind.399.10",T)
res <- sapply(test,function(x){outer.boot.func(x[1],x[2],x[3],x[4])})
 
Thanks,
 
Chushu Gu
<Prev in Thread] Current Thread [Next in Thread>