string into numeric & copy of variable label

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

string into numeric & copy of variable label

news
I have to convert a large number of string variables coded Y and N into
numeric variables which I do with  :
recode v151 v152 v153 v153b1  ('Y'=1)('N'=0) (else=-9) into n151 n152
n153 n153b1.
But how can I also copy the variable label from  v151 to n151 using syntax ?

Thanks
F. Thomas

--
..........................................
Dr. Frank Thomas
FTR Internet Research
93110 Rosny-sous-Bois
France

=====================
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
Reply | Threaded
Open this post in threaded view
|

Re: string into numeric & copy of variable label

Oliver, Richard
Try AUTORECODE.

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Frank Thomas
Sent: Thursday, April 10, 2008 11:31 AM
To: [hidden email]
Subject: string into numeric & copy of variable label

I have to convert a large number of string variables coded Y and N into
numeric variables which I do with  :
recode v151 v152 v153 v153b1  ('Y'=1)('N'=0) (else=-9) into n151 n152
n153 n153b1.
But how can I also copy the variable label from  v151 to n151 using syntax ?

Thanks
F. Thomas

--
..........................................
Dr. Frank Thomas
FTR Internet Research
93110 Rosny-sous-Bois
France

=====================
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
Reply | Threaded
Open this post in threaded view
|

Re: string into numeric & copy of variable label

Melissa Ives
That would work, but would code 1=NO and 2=YES (alphabetical).
If you then recoded, you'd still need to reset the value labels.

Value labels n151 n152 n153 n153b1 1 'Yes' 0 'No'.

Melissa

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Oliver, Richard
Sent: Thursday, April 10, 2008 11:51 AM
To: [hidden email]
Subject: Re: [SPSSX-L] string into numeric & copy of variable label

Try AUTORECODE.

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Frank Thomas
Sent: Thursday, April 10, 2008 11:31 AM
To: [hidden email]
Subject: string into numeric & copy of variable label

I have to convert a large number of string variables coded Y and N into numeric variables which I do with  :
recode v151 v152 v153 v153b1  ('Y'=1)('N'=0) (else=-9) into n151 n152
n153 n153b1.
But how can I also copy the variable label from  v151 to n151 using syntax ?

Thanks
F. Thomas

--
..........................................
Dr. Frank Thomas
FTR Internet Research
93110 Rosny-sous-Bois
France

=====================
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

PRIVILEGED AND CONFIDENTIAL INFORMATION
This transmittal and any attachments may contain PRIVILEGED AND
CONFIDENTIAL information and is intended only for the use of the
addressee. If you are not the designated recipient, or an employee
or agent authorized to deliver such transmittals to the designated
recipient, you are hereby notified that any dissemination,
copying or publication of this transmittal is strictly prohibited. If
you have received this transmittal in error, please notify us
immediately by replying to the sender and delete this copy from your
system. You may also call us at (309) 827-6026 for assistance.

=====================
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
Reply | Threaded
Open this post in threaded view
|

Re: string into numeric & copy of variable label

Oliver, Richard
Although I haven't tried it, I suspect you could create and modify an Autorecode template to give you precisely what you want.

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Melissa Ives
Sent: Thursday, April 10, 2008 11:59 AM
To: [hidden email]
Subject: Re: string into numeric & copy of variable label

That would work, but would code 1=NO and 2=YES (alphabetical).
If you then recoded, you'd still need to reset the value labels.

Value labels n151 n152 n153 n153b1 1 'Yes' 0 'No'.

Melissa

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Oliver, Richard
Sent: Thursday, April 10, 2008 11:51 AM
To: [hidden email]
Subject: Re: [SPSSX-L] string into numeric & copy of variable label

Try AUTORECODE.

-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Frank Thomas
Sent: Thursday, April 10, 2008 11:31 AM
To: [hidden email]
Subject: string into numeric & copy of variable label

I have to convert a large number of string variables coded Y and N into numeric variables which I do with  :
recode v151 v152 v153 v153b1  ('Y'=1)('N'=0) (else=-9) into n151 n152
n153 n153b1.
But how can I also copy the variable label from  v151 to n151 using syntax ?

Thanks
F. Thomas

--
..........................................
Dr. Frank Thomas
FTR Internet Research
93110 Rosny-sous-Bois
France

=====================
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

PRIVILEGED AND CONFIDENTIAL INFORMATION
This transmittal and any attachments may contain PRIVILEGED AND
CONFIDENTIAL information and is intended only for the use of the
addressee. If you are not the designated recipient, or an employee
or agent authorized to deliver such transmittals to the designated
recipient, you are hereby notified that any dissemination,
copying or publication of this transmittal is strictly prohibited. If
you have received this transmittal in error, please notify us
immediately by replying to the sender and delete this copy from your
system. You may also call us at (309) 827-6026 for assistance.

=====================
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
Reply | Threaded
Open this post in threaded view
|

Re: string into numeric & copy of variable label

news
Thank you all for the hint to look at Autorecode.
This was exactly what I searched.
- Frank Thomas

Oliver, Richard wrote:

> Although I haven't tried it, I suspect you could create and modify an Autorecode template to give you precisely what you want.
>
> -----Original Message-----
> From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Melissa Ives
> Sent: Thursday, April 10, 2008 11:59 AM
> To: [hidden email]
> Subject: Re: string into numeric & copy of variable label
>
> That would work, but would code 1=NO and 2=YES (alphabetical).
> If you then recoded, you'd still need to reset the value labels.
>
> Value labels n151 n152 n153 n153b1 1 'Yes' 0 'No'.
>
> Melissa
>
> -----Original Message-----
> From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Oliver, Richard
> Sent: Thursday, April 10, 2008 11:51 AM
> To: [hidden email]
> Subject: Re: [SPSSX-L] string into numeric & copy of variable label
>
> Try AUTORECODE.
>
> -----Original Message-----
> From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Frank Thomas
> Sent: Thursday, April 10, 2008 11:31 AM
> To: [hidden email]
> Subject: string into numeric & copy of variable label
>
> I have to convert a large number of string variables coded Y and N into numeric variables which I do with  :
> recode v151 v152 v153 v153b1  ('Y'=1)('N'=0) (else=-9) into n151 n152
> n153 n153b1.
> But how can I also copy the variable label from  v151 to n151 using syntax ?
>
> Thanks
> F. Thomas
>
> --
> ........................................
> Dr. Frank Thomas
> FTR Internet Research
> 93110 Rosny-sous-Bois
> France
>
> =====================
> 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
>
> PRIVILEGED AND CONFIDENTIAL INFORMATION
> This transmittal and any attachments may contain PRIVILEGED AND
> CONFIDENTIAL information and is intended only for the use of the
> addressee. If you are not the designated recipient, or an employee
> or agent authorized to deliver such transmittals to the designated
> recipient, you are hereby notified that any dissemination,
> copying or publication of this transmittal is strictly prohibited. If
> you have received this transmittal in error, please notify us
> immediately by replying to the sender and delete this copy from your
> system. You may also call us at (309) 827-6026 for assistance.
>
> =====================
> 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
>
> =====================
> 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
>
>
>


--
..........................................
Dr. Frank Thomas
FTR Internet Research
93110 Rosny-sous-Bois
France

=====================
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