}
input = casereader_create_filter_weight (input, dict, &warn, NULL);
+ input = casereader_create_filter_missing (input,
+ ft->vars, ft->n_vars,
+ exclude, 0, 0);
+
for (; (c = casereader_read (input)); case_unref (c))
{
double prev_x = SYSMIS;
if ( run_length > 0)
{
double t = run_length + 1;
- sigma_t += pow3 (t) - t;
+ sigma_t += w * (pow3 (t) - t);
}
run_length = 0;
}
if ( run_length > 0)
{
double t = run_length + 1;
- sigma_t += pow3 (t) - t;
+ sigma_t += w * (pow3 (t) - t );
}
qsort (row, ft->n_vars, sizeof *row, cmp_posn);
for (v = 0; v < ft->n_vars; ++v)
- fr.rank_sum[v] += row[v].x;
-
+ fr.rank_sum[v] += row[v].x * w;
}
casereader_destroy (input);
free (row);
static void
show_ranks_box (const struct one_sample_test *ost, const struct friedman *fr)
{
- const struct variable *weight = dict_get_weight (fr->dict);
- const struct fmt_spec *wfmt = weight ? var_get_print_format (weight) : &F_8_0;
-
int i;
const int row_headers = 1;
const int column_headers = 1;
TAB_LEFT, var_to_string (ost->vars[i]));
tab_double (table, 1, row_headers + i,
- 0, fr->rank_sum[i] / fr->cc, wfmt);
+ 0, fr->rank_sum[i] / fr->cc, 0);
}
tab_submit (table);
const struct variable *weight = dict_get_weight (fr->dict);
const struct fmt_spec *wfmt = weight ? var_get_print_format (weight) : &F_8_0;
- int i;
const int row_headers = 1;
const int column_headers = 0;
struct tab_table *table =