Fixed crash caused by regressing with categorical variables
authorJason H Stover <jhs@math.gcsu.edu>
Thu, 11 Jun 2009 15:31:40 +0000 (11:31 -0400)
committerJason H Stover <jhs@math.gcsu.edu>
Thu, 11 Jun 2009 15:31:40 +0000 (11:31 -0400)
src/language/stats/regression.q

index 05c08dfad145eeb6c0c9d0f38a74f2b357525741..14d4b841a478614b4d72d92481ade1d16be02be4 100644 (file)
@@ -947,7 +947,7 @@ run_regression (struct casereader *input, struct cmd_regression *cmd,
              lopts.get_indep_mean_std[i] = 1;
            }
          models[k] = pspp_linreg_cache_alloc (dep_var, (const struct variable **) indep_vars,
-                                              X->m->size1, X->m->size2);
+                                              X->m->size1, n_indep);
          models[k]->depvar = dep_var;
          /*
             For large data sets, use QR decomposition.