[R] x[x > y] and more conditions
Prof Brian Ripley
ripley at stats.ox.ac.uk
Tue Nov 18 12:04:52 CET 2003
Did you mean == not = ?
On Tue, 18 Nov 2003, Christian Schulz wrote:
> ...and i'm getting all cases which
> are true for above condition and get the information
> how many cases match, too. The vector's are in a attached data.frame.
>
> FAKTOR30[FAKTOR30 > 0.234]
> ...................
> [102193] 0.352 0.352 0.288 0.354 0.352 0.358 0.352 0.352 0.311 0.370 0.352
> 0.336
> [102205] 0.352 0.274 0.352 0.405 0.354 0.352 0.352 0.352 0.352 0.352 0.352
> 0.340
> [102217] 0.352 0.352
>
>
> But if i use more than one "index" term
> UMSATZ30[UMSATZ30 > 10] && FAKTOR30[FAKTOR30 = 0.234]
>
> [1] NA
>
> I get true, false or NA and the latter i think this mean there isn't any
> case with this condition!?
> But, how can i check cases with more than one condition like the single
> example, i trial some but getting no success?
--
Brian D. Ripley, ripley at stats.ox.ac.uk
Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel: +44 1865 272861 (self)
1 South Parks Road, +44 1865 272866 (PA)
Oxford OX1 3TG, UK Fax: +44 1865 272595
More information about the R-help
mailing list