fixed prediction bug
[pspp-builds.git] / src / math / linreg / predict.c
index 0bab23c8cd89f0b9bcd66ac6fb1cf69cbce72a7b..49e24434b5ff5cca2ae5ae1d95ecffc335b06040 100644 (file)
@@ -62,7 +62,7 @@ pspp_linreg_predict (const struct variable **predictors,
     {
       coe = pspp_linreg_get_coeff (c, predictors[j], vals[j]);
       i = 1;
-      while (found[i] != coe && i < c->n_coeffs)
+      while (found[i] == coe && i < c->n_coeffs)
        {
          i++;
        }