projects
/
pspp
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0891406
)
SUBTABLE works (I'm suspicous about ROW though)
author
Ben Pfaff
<blp@cs.stanford.edu>
Sat, 13 Aug 2022 22:44:02 +0000
(15:44 -0700)
committer
Ben Pfaff
<blp@cs.stanford.edu>
Sat, 13 Aug 2022 22:44:02 +0000
(15:44 -0700)
src/language/stats/ctables.c
patch
|
blob
|
history
diff --git
a/src/language/stats/ctables.c
b/src/language/stats/ctables.c
index 836a974d824dda2f6f00c7cffa96df4e4b97c559..341e68e0d9039c3b4a7cc5b85aaed688e40614f5 100644
(file)
--- a/
src/language/stats/ctables.c
+++ b/
src/language/stats/ctables.c
@@
-4689,6
+4689,17
@@
ctables_prepare_table (struct ctables_table *t)
}
}
+ if (at == CTAT_SUBTABLE && t->label_axis[PIVOT_AXIS_ROW] == PIVOT_AXIS_COLUMN)
+ {
+ size_t n_drop = (a == PIVOT_AXIS_LAYER ? 0
+ : a == PIVOT_AXIS_ROW ? 2
+ : 0);
+ for (size_t i = 0; i < n_drop; i++)
+ if (nest->n_areas[at] > 0)
+ nest->n_areas[at]--;
+ continue;
+ }
+
bool drop_last = (at == CTAT_SUBTABLE ? a != PIVOT_AXIS_LAYER
: at == CTAT_ROW ? a == PIVOT_AXIS_COLUMN
: at == CTAT_COL ? a == PIVOT_AXIS_ROW