Hallo, I have a vector of several iterations and I have to remove /filter out all the values < than 10, how can I do this? Thanks a lot Alessandra -- View this message in context: http://www.nabble.com/removing-value-from-a-vector-tp24250608p24250608.html Sent from the R help mailing list archive at Nabble.com.
Try this: x[!x < 10] On Mon, Jun 29, 2009 at 5:58 AM, aledanda <danda.galli@gmail.com> wrote:> > Hallo, > > I have a vector of several iterations and I have to remove /filter out all > the values < than 10, > how can I do this? > > Thanks a lot > > Alessandra > -- > View this message in context: > http://www.nabble.com/removing-value-from-a-vector-tp24250608p24250608.html > Sent from the R help mailing list archive at Nabble.com. > > ______________________________________________ > R-help@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. >-- Henrique Dallazuanna Curitiba-Paraná-Brasil 25° 25' 40" S 49° 16' 22" O [[alternative HTML version deleted]]
Hi r-help-bounces at r-project.org napsal dne 29.06.2009 10:58:50:> > Hallo, > > I have a vector of several iterations and I have to remove /filter outall> the values < than 10, > how can I do this?vector[vector>=10] does what you want but word "vector of iterations" frightens me a little. Seems to me that you have some programme and you populate some "vector"? with values and you do not want to enter values lower than 10. In that case if ... else ... could be solution. But who knows? Regards Petr> > Thanks a lot > > Alessandra > -- > View this message in context:http://www.nabble.com/removing-value-from-a-> vector-tp24250608p24250608.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 guidehttp://www.R-project.org/posting-guide.html> and provide commented, minimal, self-contained, reproducible code.