mercredi 25 novembre 2015

Two kinds of test over the same variables giving different results

In LibreOffice Calc I have an array of values to be evaluated whether they are or are not within the interval. I performed two tests, one asks if the values are within the bounds, another asks if the values are lower than the lower bound or bigger than the upper bound. Now, with the same value and the same bounds, the two tests should give the same answer. But this is not the case. Here are the tests I performed:

=IF((P4-S4)<=I4<=(P4+S4);"WITHIN";"OUTSIDE")
=IF(OR((P4-S4)>I4;(P4+S4)<I4);"OUTSIDE";"COMPRESO")

Note the sum because it's a confidence interval, where P4 is the sample mean and +- S4 are the statistics; with the first test I get a "WITHIN" asking whether 2 is within 2.26 and 2.66 -.-" and with the second test I get "OUTSIDE".

Where am I wrong? I can't see the mistake.

Aucun commentaire:

Enregistrer un commentaire