Date: Fri, 31 Mar 2006 07:06:26 -0500
Reply-To: Arild S <kog@SSB.NO>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Arild S <kog@SSB.NO>
Subject: Re: New variable based on FORMAT
On Fri, 31 Mar 2006 03:26:07 -0800, RasmusJo <rjo.cebr@CBS.DK> wrote:
>Is it possible to generate variables based on formats?
>Consider the following example:
>0-10 = 1
>11-20 = 2
>format wealth group.;
>input id wealth;
>Is it possible to recode wealth in accordance with the format 'group'?
>For instance, I would like to do a proc freq where I can condition on
it's a PUT with the format:
wealthgroup = put(wealth, group.);
(or wealth = put(wealth, group.); if
you want to overwrite/ recode it, but why..
or just proc freq .. where 0<=wealth<=10; ? )