const struct two_sample_test *t2s = UP_CAST (test, const struct two_sample_test, parent);
struct ccase *c;
- struct sign_test_params *stp = xcalloc (t2s->n_pairs, sizeof *stp);
+ struct sign_test_params *stp = XCALLOC (t2s->n_pairs, struct sign_test_params);
struct casereader *r = input;
{
const double weight = dict_get_case_weight (dict, c, &warn);
- for (i = 0 ; i < t2s->n_pairs; ++i )
+ for (i = 0 ; i < t2s->n_pairs; ++i)
{
variable_pair *vp = &t2s->pairs[i];
const union value *value0 = case_data (c, (*vp)[0]);
const union value *value1 = case_data (c, (*vp)[1]);
const double diff = value0->f - value1->f;
- if (var_is_value_missing ((*vp)[0], value0, exclude))
+ if (var_is_value_missing ((*vp)[0], value0) & exclude)
continue;
- if (var_is_value_missing ((*vp)[1], value1, exclude))
+ if (var_is_value_missing ((*vp)[1], value1) & exclude)
continue;
- if ( diff > 0)
+ if (diff > 0)
stp[i].pos += weight;
else if (diff < 0)
stp[i].neg += weight;
casereader_destroy (r);
- for (i = 0 ; i < t2s->n_pairs; ++i )
+ for (i = 0 ; i < t2s->n_pairs; ++i)
{
int r = MIN (stp[i].pos, stp[i].neg);
stp[i].one_tailed_sig = gsl_cdf_binomial_P (r,