Thanks for the hint's, and sorry for my confusing, which come from my sql activity which need && or AND.
regards,christian -----Ursprungliche Nachricht----- Von: Uwe Ligges [mailto:[EMAIL PROTECTED] Gesendet: Dienstag, 18. November 2003 11:29 An: Christian Schulz Cc: R-Help Betreff: Re: [R] x[x > y] and more conditions 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 See ?"&&" which tells you to use "&" instead os "&&" for vectorized logical operations like this one. Using "&&" only evaluates the first elements of those logical vectors, so there seems to be an NA in UMSATZ30[1] or FAKTOR30[1].... Uwe Ligges > 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? > > Many thanks for help, > christian > > ______________________________________________ > [EMAIL PROTECTED] mailing list > https://www.stat.math.ethz.ch/mailman/listinfo/r-help > ______________________________________________ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help