-/* PSPP - computes sample statistics. -*-c-*-
-
+/* PSPP - a program for statistical analysis.
Copyright (C) 1997-9, 2000 Free Software Foundation, Inc.
- This program is free software; you can redistribute it and/or
- modify it under the terms of the GNU General Public License as
- published by the Free Software Foundation; either version 2 of the
- License, or (at your option) any later version.
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
- This program is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
- 02110-1301, USA. */
+ along with this program. If not, see <http://www.gnu.org/licenses/>. */
#include <config.h>
#include <gsl/gsl_cdf.h>
#include <math.h>
+#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <language/command.h>
#include <language/dictionary/split-file.h>
#include <language/lexer/lexer.h>
-#include <libpspp/alloc.h>
#include <libpspp/assertion.h>
#include <libpspp/compiler.h>
#include <libpspp/hash.h>
-#include <libpspp/magic.h>
#include <libpspp/message.h>
#include <libpspp/misc.h>
#include <libpspp/str.h>
#include <output/manager.h>
#include <output/table.h>
-#include "size_max.h"
+#include "xalloc.h"
#include "gettext.h"
#define _(msgid) gettext (msgid)
static struct pair *pairs=0;
-static int parse_value (struct lexer *lexer, union value * v, enum var_type);
+static int parse_value (struct lexer *lexer, union value * v, enum val_type);
/* Structures and Functions for the Statistics Summary Box */
struct ssbox;
{
free (vars);
msg (SE, _("PAIRED was specified but the number of variables "
- "preceding WITH (%d) did not match the number "
- "following (%d)."),
- (int) n_before_WITH, (int) n_after_WITH );
+ "preceding WITH (%zu) did not match the number "
+ "following (%zu)."),
+ n_before_WITH, n_after_WITH);
return 0;
}
n_pairs_local = n_before_WITH;
/* Parses the current token (numeric or string, depending on type)
value v and returns success. */
static int
-parse_value (struct lexer *lexer, union value * v, enum var_type type)
+parse_value (struct lexer *lexer, union value * v, enum val_type type)
{
- if (type == VAR_NUMERIC)
+ if (type == VAL_NUMERIC)
{
if (!lex_force_num (lexer))
return 0;
if (gp.criterion == CMP_LE )
{
- strcpy(prefix[0],"< ");
- strcpy(prefix[1],">=");
+ strcpy(prefix[0],">=");
+ strcpy(prefix[1],"<");
indep_value[0] = gp.v.critical_value;
indep_value[1] = gp.v.critical_value;
}
{
if ( count == 0 )
{
- /* less than ( < ) case */
- search_val.f = gp.v.critical_value - 1.0;
+ /* >= case */
+ search_val.f = gp.v.critical_value + 1.0;
}
else
{
- /* >= case */
- search_val.f = gp.v.critical_value + 1.0;
+ /* less than ( < ) case */
+ search_val.f = gp.v.critical_value - 1.0;
}
}
else
}
hsh_insert ( ttpr->group_hash, (void *) gs );
-
}
}
enum mv_class exclude = cmd->miss != TTS_INCLUDE ? MV_ANY : MV_SYSTEM;
if (!casereader_peek (input, 0, &c))
- return;
+ {
+ casereader_destroy (input);
+ return;
+ }
output_split_file_values (ds, &c);
case_destroy (&c);
trbox_populate(&test_results_box,cmd);
trbox_finalize(&test_results_box);
}
+
+ taint_destroy (taint);
}
short which_group(const struct group_statistics *g,
if ( p->criterion == CMP_LE )
{
- /* less-than-or-equal comparision is not meaningfull for
+ /* less-than comparision is not meaningfull for
alpha variables, so we shouldn't ever arrive here */
assert(p->indep_width == 0 ) ;
return 2;
}
+/*
+ Local Variables:
+ mode: c
+ End:
+*/