Hi Gabor
thanks for this.
On 21 Nov 2005, at 13:26, Gabor Grothendieck wrote:
> Try this:
>
> tapply(a, row(a), f, simplify = FALSE)
>
[
here
a <- cbind(1:5 , 5:1)
f <- function(x){list(1:max(x[1],4))}
]
This also works. I actually need unlist(... , recursive=FALSE)
to pass the list to do.call() but that 's fine.
But, my question here is: how does one arrive at
such a solution from the manpage? The manpage seems
to indicate that the first argument to tapply() is a ragged
array, or a vector.
I can't reconcile Gabor's use of tapply() with the manpage.
How to understand Gabor's suggestion better?
>>
--
Robin Hankin
Uncertainty Analyst
National Oceanography Centre, Southampton
European Way, Southampton SO14 3ZH, UK
tel 023-8059-7743
______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html