projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
message: Get rid of 'shipped' member in struct message.
[pspp]
/
src
/
language
/
stats
/
roc.c
diff --git
a/src/language/stats/roc.c
b/src/language/stats/roc.c
index 5f8da6df55e04f0ea0e3b07677513fc55fe31891..b3f8e91e47da59645d04f83cfa75ae66a4f3ff88 100644
(file)
--- a/
src/language/stats/roc.c
+++ b/
src/language/stats/roc.c
@@
-33,7
+33,6
@@
#include "language/lexer/variable-parser.h"
#include "libpspp/misc.h"
#include "math/sort.h"
#include "language/lexer/variable-parser.h"
#include "libpspp/misc.h"
#include "math/sort.h"
-#include "output/chart-item.h"
#include "output/charts/roc-chart.h"
#include "output/pivot-table.h"
#include "output/charts/roc-chart.h"
#include "output/pivot-table.h"
@@
-1062,7
+1061,6
@@
show_coords (struct roc_state *rs, const struct cmd_roc *roc)
{
struct pivot_table *table = pivot_table_create (
N_("Coordinates of the Curve"));
{
struct pivot_table *table = pivot_table_create (
N_("Coordinates of the Curve"));
- table->look.omit_empty = true;
pivot_dimension_create (table, PIVOT_AXIS_COLUMN, N_("Statistics"),
N_("Positive if greater than or equal to"),
pivot_dimension_create (table, PIVOT_AXIS_COLUMN, N_("Statistics"),
N_("Positive if greater than or equal to"),
@@
-1095,6
+1093,13
@@
show_coords (struct roc_state *rs, const struct cmd_roc *roc)
const double sp = case_data_idx (cc, ROC_TN)->f /
(case_data_idx (cc, ROC_TN)->f + case_data_idx (cc, ROC_FP)->f);
const double sp = case_data_idx (cc, ROC_TN)->f /
(case_data_idx (cc, ROC_TN)->f + case_data_idx (cc, ROC_FP)->f);
+ if (coord_idx >= n_coords)
+ {
+ assert (coord_idx == n_coords);
+ pivot_category_create_leaf (
+ coordinates->root, pivot_value_new_integer (++n_coords));
+ }
+
pivot_table_put3 (
table, 0, coord_idx, var_idx,
pivot_value_new_var_value (roc->vars[i],
pivot_table_put3 (
table, 0, coord_idx, var_idx,
pivot_value_new_var_value (roc->vars[i],
@@
-1107,16
+1112,9
@@
show_coords (struct roc_state *rs, const struct cmd_roc *roc)
coord_idx++;
}
coord_idx++;
}
- if (coord_idx > n_coords)
- n_coords = coord_idx;
-
casereader_destroy (r);
}
casereader_destroy (r);
}
- for (size_t i = 0; i < n_coords; i++)
- pivot_category_create_leaf (coordinates->root,
- pivot_value_new_integer (i + 1));
-
pivot_table_submit (table);
}
pivot_table_submit (table);
}