Date: Tue, 20 Apr 2004 13:40:23 -0400
Reply-To: "Hetter, Rebecca D,,DMDCWEST" <HETTERRD@osd.pentagon.mil>
Sender: "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU>
From: "Hetter, Rebecca D,,DMDCWEST" <HETTERRD@osd.pentagon.mil>
Subject: Re: Joining two numeric variables
Content-Type: text/plain
This assumes that the student id has 6-digits. The "formats" statement is
needed to preserve leading zeros in the original variables:
formats site(n4) stid(n6).
string newvar(a10).
compute newvar= concat(string(site,n4),string(stid,n6)).
-----Original Message-----
From: Don Baker [mailto:DRRALPH@OU.EDU]
Sent: Tuesday, April 20, 2004 10:10 AM
To: SPSSX-L@LISTSERV.UGA.EDU
Subject: Joining two numeric variables
I want to join (concatenate) the values of two numeric variables into a new
variable. One variable is a four digit coalition site number and the other
is a student id number. By joining the two variables I will be able to
create a set of unique id numbers across several coalition sites.
Any suggestions?
|