FORMAT
[pspp] / tests / language / stats / ctables.at
index cfa39ec3a3503af7888eb0db6cacfed9c047e6e3..0453eeb1e8ea11c7f3fae648caaadb5d4f0664cf 100644 (file)
@@ -17,7 +17,6 @@ dnl   * THRU (numeric ranges)
 dnl   * OTHERNM
 dnl - FORMAT:
 dnl   * MINCOLWIDTH, MAXCOLWIDTH, UNITS.
-dnl   * MISSING.
 dnl - HIDESMALLCOUNTS.
 dnl - Date/time variables and values
 dnl - Special formats for summary functions: NEGPAREN, NEQUAL, PAREN, PCTPAREN.
@@ -2253,4 +2252,36 @@ AT_CHECK([pspp ctables.sps -O box=unicode], [0], [dnl
 │                             one             │               │               │
 ╰─────────────────────────────────────────────┴───────────────┴───────────────╯
 ])
+AT_CLEANUP
+
+AT_SETUP([CTABLES FORMAT=MISSING])
+AT_KEYWORDS([FORMAT MISSING])
+AT_CHECK([ln $top_srcdir/examples/nhtsa.sav . || cp $top_srcdir/examples/nhtsa.sav .])
+AT_DATA([ctables.sps],
+[[GET 'nhtsa.sav'.
+CTABLES /FORMAT MISSING='(no data)' /TABLE qnd5a[COLPCT] BY qnd5.
+]])
+AT_CHECK([pspp ctables.sps -O box=unicode], [0], [dnl
+                                 Custom Tables
+╭─────────────────────────────────────────────┬───────────────────────────────╮
+│                                             │   D5. ETHNICITY: Are you of   │
+│                                             │  Hispanic or Latino origin or │
+│                                             │            descent?           │
+│                                             ├───────────────┬───────────────┤
+│                                             │      Yes      │       No      │
+│                                             ├───────────────┼───────────────┤
+│                                             │    Column %   │    Column %   │
+├─────────────────────────────────────────────┼───────────────┼───────────────┤
+│D5a. What would you say is   Cuban           │           3.2%│(no data)      │
+│your primary ethnic          Mexican         │          50.3%│(no data)      │
+│background?                  Spanish         │           7.8%│(no data)      │
+│                             South American  │           5.5%│(no data)      │
+│                             Central American│           8.4%│(no data)      │
+│                             Puerto Rican, OR│          12.6%│(no data)      │
+│                             Something else  │          11.0%│(no data)      │
+│                             Multiple -      │           1.1%│(no data)      │
+│                             cannot choose   │               │               │
+│                             one             │               │               │
+╰─────────────────────────────────────────────┴───────────────┴───────────────╯
+])
 AT_CLEANUP
\ No newline at end of file