| Date: | Wed, 22 Feb 2012 12:45:48 +0100 |
| Reply-To: | John F Hall <johnfhall@orange.fr> |
| Sender: | "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU> |
| From: | John F Hall <johnfhall@orange.fr> |
| Subject: | Re: Counting |
|
| In-Reply-To: | <CAJ-5AarxKVupx0C7fpMRKX7bu+4LF4nF2yjo-ufCXOpv-ZkDzQ@mail.gmail.com> |
| Content-Type: | multipart/alternative;
|
|---|
Yes, but you have to enclose the string values in primes, eg:
COUNT SVAR=V1 V2 ('male ') V3 V4 V5 ('female').
John Hall
Email: johnfhall@orange.fr
Website: www.surveyresearch.weebly.com <http://surveyresearch.weebly.com/>
Skype: surveyresearcher1
Phone: (+33) (0) 2.33.45.91.47
From: Zhenzhen Wang [mailto:wzzjasmine@gmail.com]
Sent: 22 February 2012 10:20
To: John F Hall
Subject: Re: Counting
Dear Hall,
Can the syntax deal with string variables?
Zhenzhen
2012/2/22 John F Hall <johnfhall@orange.fr>
Tom
Marcia used the GUI: I always use syntax, so substitute your own varname(s)
and value in:
count <newvar> = <varlist> (<value>) .
There are some examples on
http://surveyresearch.weebly.com/-35-derived-variables-count-and-compute.htm
l on my website.
John Hall (Mr)
Email: johnfhall@orange.fr
Website: www.surveyresearch.weebly.com <http://surveyresearch.weebly.com/>
Skype: surveyresearcher1
Phone: (+33) (0) 2.33.45.91.47
<tel:%28%2B33%29%20%280%29%202.33.45.91.47>
From: SPSSX(r) Discussion [mailto:SPSSX-L@LISTSERV.UGA.EDU] On Behalf Of
Balmer, Thomas
Sent: 22 February 2012 09:27
To: SPSSX-L@LISTSERV.UGA.EDU
Subject: Counting
Hi
I'd like to count, how many times a certain value appears in a range of
variables and write this number (the amount of the appearance of the value)
in a new variable.
I couldn't find any function in the menu - perhaps it can be done by the
syntax?
Thanks for hints !
Tom
--
Department of Media and Communication
City University of Hong Kong
[text/html]
|