Try:
compute like = 0.
count like = q1, q2, q3 (1).
recode like (2,3=1).
format like (f1.0).
freq like.
What will you do if 100% like fruit?
-----Original Message-----
From: SPSSX(r) Discussion [mailto:
[hidden email]] On Behalf Of Art
Kendall
Sent: 19 May 2017 18:02
To:
[hidden email]
Subject: Re: How can I combine three yes/no questions into one?
there might be substantive reasons to ask how many of these are liked, as
well as if ANY are liked.data list list /Id (F3) apple pear orange (3f1).
begin data
1 0 0 1
2 0 1 0
3 1 0 0
4 1 0 1
5 1 1 0
6 1 1 1
7 0 1 1
8 0 0 0
end data.
numeric N_fruit1, N_fruit2, Any_fruit (f1).
value labels apple pear orange 1 'yes' 0 'no'.
count N_fruit1 = apple pear orange(1).
compute N_fruit2 = sum(apple, pear, orange).
compute Any_fruit = any(1, apple, pear, orange).
list.
-----
Art Kendall
Social Research Consultants
--
View this message in context:
http://spssx-discussion.1045642.n5.nabble.com/How-can-I-combine-three-yes-no-questions-into-one-tp5734209p5734210.html
Sent from the SPSSX Discussion mailing list archive at 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
=====================
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