[R] vector vs array

alessandro carletti alxmilton at yahoo.it
Mon Aug 8 17:34:54 CEST 2005


Hi!
OK, I'm trying to select some "useful outliers" from
my dataset: I defined 11 "treshold" values (1 for each
level of a variable (sampling site) as follows:


tresholds<-function(x)
{
tapply(x,mm$NAME,FUN=mean ,simplify = T, na.rm=T)->med


tapply(x,mm$NAME,FUN=sd ,simplify = T,
na.rm=T)->standev 

standev+med

}
tresholds(mm$chl)


Now I'd like to select those values from vector mm$chl
that are higher than each "treshold value", but how
can I compare a vector with 1885 elements with the one
with 11?
Sorry for this (probably) stupid question...
and thanks in advance.
Alessandro




More information about the R-help mailing list