sort (iap->reverse_interaction_value_map, x, sizeof (*iap->reverse_interaction_value_map),
compare_interaction_value_3way, iap);
+ /* Fill the remaining values with null */
+ for (ii = x ; ii < iap->n_cats; ++ii)
+ iap->reverse_interaction_value_map[ii] = NULL;
+
/* Populate the reverse variable maps. */
for (ii = 0; ii < iap->df; ++ii)
cat->reverse_variable_map_short[idx_short++] = i;
int vindex = reverse_variable_lookup_short (cat, subscript);
const struct interact_params *vp = &cat->iap[vindex];
const struct interaction_value *vn = vp->reverse_interaction_value_map [subscript - vp->base_subscript_short];
+
+ if ( vn == NULL)
+ return NULL;
+
return vn->ccase;
}
const struct interaction_value *iv = vp->reverse_interaction_value_map [subscript - vp->base_subscript_short];
+ if (iv == NULL)
+ return 0;
+
return iv->cc;
}
const struct ccase *c2 = categoricals_get_case_by_subscript (cat, subscript);
+ if ( c2 == NULL)
+ return 0;
+
return interaction_case_equal (iact, c, c2);
}