- for ( gs = hsh_first(gp->group_hash, &hi);
- gs != 0;
- gs = hsh_next(gp->group_hash, &hi))
- {
- gs->lz_total = 0;
- }
-
- }
-
-}
-
-static int
-levene_calc (const struct ccase *c, void *_l)
-{
- size_t i;
- int warn = 0;
- struct levene_info *l = (struct levene_info *) _l;
- const union value *gv = case_data (c, l->v_indep->fv);
- struct group_statistics key;
- double weight = dict_get_case_weight(default_dict,c,&warn);
-
- /* Skip the entire case if /MISSING=LISTWISE is set */
- if ( l->missing == LEV_LISTWISE )
- {
- for (i = 0; i < l->n_dep; ++i)
- {
- struct variable *v = l->v_dep[i];
- const union value *val = case_data (c, v->fv);
-
- if (l->is_missing (&v->miss, val) )
- {
- return 0;
- }
- }
- }
-
-
- key.id = *gv;
-
- for (i = 0; i < l->n_dep; ++i)
- {
- struct variable *var = l->v_dep[i];
- struct group_proc *gp = group_proc_get (var);
- double levene_z;
- const union value *v = case_data (c, var->fv);
- struct group_statistics *gs;
-
- gs = hsh_find(gp->group_hash,(void *) &key );
-
- if ( 0 == gs )
- continue ;
-
- if ( ! l->is_missing(&var->miss, v))