I am trying to create a list of variables that have specific values on some
custom attributes. For example, I would like to have a list of numeric variable names I can paste into syntax that have the value 'Water' on the custom attribute "[Var.Grouping]" AND the value 'Computed' on the custom attribute "[Source]" SPSSINC SELECT VARIABLES MACRONAME = '!MyVarList1' /PROPERTIES TYPE=NUMERIC /ATTRHASALL 'Var.Grouping' 'Source' /ATTRVALUES NAME ='Var.Grouping' VALUE="Water" NAME1='Source' VALUE="Computed" /OPTIONS ORDER=FILE PRINT=YES. Warnings Subcommand ATTRVALUES: NAME must specify a single, valid variable name. Execution of this command stops. ----- Art Kendall Social Research Consultants -- Sent from: http://spssx-discussion.1045642.n5.nabble.com/ ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD
Art Kendall
Social Research Consultants |
This would work. SPSSINC SELECT VARIABLES MACRONAME = '!MyVarList1' /PROPERTIES TYPE=NUMERIC /ATTRHASALL 'Var.Grouping' 'Source' /ATTRVALUES NAME =Var.Grouping VALUE="Water" NAME1=Source VALUE1="Computed" /OPTIONS ORDER=FILE PRINT=YES. The attribute names should not be quoted, because they follow the rules for variable names. The VALUE keyword can't be reused. For NAME1, you would use VALUE1 etc. On Sat, Mar 27, 2021 at 9:30 AM Art Kendall <[hidden email]> wrote: I am trying to create a list of variables that have specific values on some |
Thank you it worked. It is always little things.
SPSSINC SELECT VARIABLES MACRONAME = '!MyVarList1' /PROPERTIES TYPE=NUMERIC /ATTRHASALL 'Var.Grouping' 'Source' /ATTRVALUES NAME =Var.Grouping VALUE="Water" NAME1=Source VALUE1="computed" /OPTIONS ORDER=FILE PRINT=YES. * for the purpose of the archive, one can use the MACRONAME like the line below. frequencies variables =!MyVarlist1. ----- Art Kendall Social Research Consultants -- Sent from: http://spssx-discussion.1045642.n5.nabble.com/ ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD
Art Kendall
Social Research Consultants |
Free forum by Nabble | Edit this page |