case: Introduce new functions for numbers and substrings in cases.
[pspp] / src / math / categoricals.c
index 4e6d8dad7ad942c633c7dc79820b93bc43d01ea6..28d51a9dd704f5bc3a8937b496f05ac0e9cda94c 100644 (file)
@@ -367,7 +367,7 @@ categoricals_update (struct categoricals *cat, const struct ccase *c)
   assert (!cat->cat_to_iact);
 
   double weight;
-  weight = cat->wv ? case_data (c, cat->wv)->f : 1.0;
+  weight = cat->wv ? case_num (c, cat->wv) : 1.0;
   weight = var_force_valid_weight (cat->wv, weight, NULL);
 
   /* Update the frequency table for each variable. */