Hi
I'm trying to create generic syntax to show all scale variables similar to: CTABLES /VLABELS VARIABLES=Q_10 VAR00001 DISPLAY=LABEL /TABLE Q_10 [S][MEAN, MEDIAN, MODE, VALIDN F40.0] BY VAR00001 /CATEGORIES VARIABLES=VAR00001 ORDER=A KEY=VALUE EMPTY=EXCLUDE How many full time employees does your whole company/organisation have in total? VAR00001 = Total Mean Median Mode Valid N 449 58 10 102 but instead of just Q_10 I want all scale variables, I've tried numerous variations on the syntax below but I cannot get it right CTABLES /VLABELS SELECT IF (VARIABLE LEVEL {SCALE}) VAR00001 DISPLAY=LABEL /TABLE (VARIABLE LEVEL {SCALE}) [S][MEAN, MEDIAN, MODE, VALIDN F40.0] BY VAR00001 /CATEGORIES VARIABLES=VAR00001 ORDER=A KEY=VALUE EMPTY=EXCLUDE Any advice would be much appreciated. |
In order to select all the scale variables for use in CTABLES, use syntax like this. SPSSINC SELECT VARIABLES MACRONAME="!scale" /PROPERTIES LEVEL=SCALE /OPTIONS SEPARATOR="+". This is an extension command normally installed with Statistics (Utilities > Define Variable Macro). It generates a macro listing all the scale variables using + as the separator. Then in CTABLES do something like CTABLES /TABLE !scale [MEAN] BY var00001 /CATEGORIES VARIABLES=var00001 /CRITERIA CILEVEL=95. On Tue, Aug 22, 2017 at 1:13 PM, [hidden email] <[hidden email]> wrote: Hi |
Free forum by Nabble | Edit this page |