[R] by function ??

Ista Zahn istazahn at gmail.com
Wed Dec 9 02:53:53 CET 2009


Hi,
I think you want

by(TestData[ , "RATIO"], LEAID, median)

-Ista

On Tue, Dec 8, 2009 at 8:36 PM, L.A. <romsa at millect.com> wrote:
>
> I'm just learning and this is probably very simple, but I'm stuck.
>   I'm trying to understand the by().
> This works.
> by(TestData, LEAID, summary)
>
> But, This doesn't.
>
> by(TestData, LEAID, median(RATIO))
>
>
> ERROR: could not find function "FUN"
>
> HELP!
> Thanks,
> LA
> --
> View this message in context: http://n4.nabble.com/by-function-tp955789p955789.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



-- 
Ista Zahn
Graduate student
University of Rochester
Department of Clinical and Social Psychology
http://yourpsyche.org




More information about the R-help mailing list