LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (July 2008, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Mon, 7 Jul 2008 15:48:11 -0500
Reply-To:     "data _null_," <datanull@GMAIL.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         "data _null_," <datanull@GMAIL.COM>
Subject:      Re: Sample 26140: Creating a new data set for each BY-Group in a
              data set
Comments: To: SAS_learner <proccontents@gmail.com>
In-Reply-To:  <c2192a610807071342g4282c04hb0c053b48355a1d@mail.gmail.com>
Content-Type: text/plain; charset=ISO-8859-1

Why do you think you need to do this? Unless you need to send the data to separate individuals or locations it is surely better to keep all the data together.

On 7/7/08, SAS_learner <proccontents@gmail.com> wrote: > hello guys, > > Similar to Sample 26140 (http://support.sas.com/kb/26/140.html) in my > dataset there can be n different treatments ( Numeric) and I want to make > them into different datasets.Some how It does not allowing me to do, I am > not sure what I am doing wrong > This is when I changed the trtgrp1 to character (Which I do not want to ) > but still no luck > > Data aa_trans; > set aa_trans; > Trtgrp2 = trtgrp1*1 /*It was not converting straight away */ ; > Trtgrp3 = Trim(Left((Put(Input(Trtgrp2 ,best12.),$4.))) ; > Run; > > %macro > break(byval); > > data &byval; > set aa_trans(where=(trtgrp3="&byval")); > > run; > > %mend; > > Proc Sort data = aa_trans ;; > By trtgrp1; > Run; > data _null_; > Set aa_trans ; > By trtgrp1 ; > if First.trtgrp1 then > Call Execute(%nrstr('%break(!!trim(trtgrp1)!!')')); > Run; > Quit; > > Even after changing it to character it is still not working any Ideas ?? > Thanks for the help >


Back to: Top of message | Previous page | Main SAS-L page