AT_BANNER([CTABLES]) AT_SETUP([CTABLES parsing]) AT_DATA([ctables.sps], [[DATA LIST LIST NOTABLE /x y z. CTABLES /TABLE=(x + y) > z. CTABLES /TABLE=(x[c] + y[c]) > z. CTABLES /TABLE=(x + y) > z[c]. CTABLES /TABLE=x BY y BY z. CTABLES /TABLE=x[c] [ROWPCT.COUNT] > y[c]. CTABLES /TABLE=x[c] > y[c] [ROWPCT.COUNT]. ]]) AT_CHECK([pspp ctables.sps]) AT_CLEANUP AT_SETUP([CTABLES one categorical variable]) AT_CHECK([ln $top_srcdir/examples/nhtsa.sav . || cp $top_srcdir/examples/nhtsa.sav .]) AT_DATA([ctables.sps], [[GET 'nhtsa.sav'. CTABLES /TABLE QN1. CTABLES /TABLE BY QN1. CTABLES /TABLE BY BY QN1. ]]) AT_CHECK([pspp ctables.sps -O box=unicode -O width=80], [0], [dnl Custom Tables ╭────────────────────────────────────────────────────────────────────────┬─────╮ │ │Count│ ├────────────────────────────────────────────────────────────────────────┼─────┤ │ 1. How often do you usually drive a car or other Every day │ 4667│ │motor vehicle? Several days a week │ 1274│ │ Once a week or less │ 361│ │ Only certain times a │ 130│ │ year │ │ │ Never │ 540│ ╰────────────────────────────────────────────────────────────────────────┴─────╯ Custom Tables ╭──────────────────────────────────────────────────────────────────────────────╮ │ 1. How often do you usually drive a car or other motor vehicle? │ ├─────────┬──────────────────┬──────────────────┬────────────────────────┬─────┤ │ │ Several days a │ Once a week or │ Only certain times a │ │ │Every day│ week │ less │ year │Never│ ├─────────┼──────────────────┼──────────────────┼────────────────────────┼─────┤ │ Count │ Count │ Count │ Count │Count│ ├─────────┼──────────────────┼──────────────────┼────────────────────────┼─────┤ │ 4667│ 1274│ 361│ 130│ 540│ ╰─────────┴──────────────────┴──────────────────┴────────────────────────┴─────╯ Custom Tables Every day ╭─────╮ │Count│ ├─────┤ │ 4667│ ╰─────╯ ]) AT_CLEANUP AT_SETUP([CTABLES one scale variable]) AT_CHECK([ln $top_srcdir/examples/nhtsa.sav . || cp $top_srcdir/examples/nhtsa.sav .]) AT_DATA([ctables.sps], [[GET 'nhtsa.sav'. CTABLES /TABLE QND1[COUNT, MEAN, STDDEV, MINIMUM, MAXIMUM]. CTABLES /TABLE BY QND1. CTABLES /TABLE BY BY QND1. ]]) AT_CHECK([pspp ctables.sps -O box=unicode -O width=80], [0], [dnl Custom Tables ╭──────────────────────────┬─────┬────┬─────────────┬───────┬───────╮ │ │Count│Mean│Std Deviation│Minimum│Maximum│ ├──────────────────────────┼─────┼────┼─────────────┼───────┼───────┤ │D1. AGE: What is your age?│ 6930│ 48│ 19│ 16│ 86│ ╰──────────────────────────┴─────┴────┴─────────────┴───────┴───────╯ Custom Tables ╭──────────────────────────╮ │D1. AGE: What is your age?│ ├──────────────────────────┤ │ Mean │ ├──────────────────────────┤ │ 48│ ╰──────────────────────────╯ Custom Tables D1. AGE: What is your age? ╭────╮ │Mean│ ├────┤ │ 48│ ╰────╯ ]) AT_CLEANUP