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 (October 2004, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Fri, 15 Oct 2004 07:30:21 -0700
Reply-To:     shanky <shankardasm@BLUEBOTTLE.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         shanky <shankardasm@BLUEBOTTLE.COM>
Organization: http://groups.google.com
Subject:      Re: rows
Content-Type: text/plain; charset=ISO-8859-1

Hi Avikram Nuriel:

You could use proc transpose for observations as variables and vice versa.

the program for your example would look like this:

data one; proc sort data=one; by id; run; proc transpose data=one out=two; by id id id; var x;

proc print data=two; run;

Hope it helps to solve your problem;

Shanky

Avikam Nuriel <mshope@cc.huji.ac.il> wrote in message news:<Pine.GSO.4.60.0410140909280.10544@nn-shum>... > Hi, > > this is my data: > > id x > 1 101 > 1 141 > 1 16 > 1 143 > 2 101 > 3 701 > 3 543 > . > . > . > > I want to change it to: > > id x1 x2 x3 x4 > 1 101 141 16 143 > 2 101 > 3 701 543 > > > and so on. > > regards > Avikam Nuriel > The Hebrew University > of Jerusalem > Israel


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