Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: reshape problem


From   Richard Hiscock <[email protected]>
To   [email protected]
Subject   st: reshape problem
Date   Sun, 20 May 2012 10:49:05 +1000

Hi All, 
I would be grateful for help with the following:
I have a repeated measures data set (for time with 24 hour points) and three continuous measures for each of 23 subjects. Unfortunatly these have been presented to me (via spreadsheet) arranged as


rows               24 time points, one point is a single row
columns            groups of 4 x 23 subjects given as    id1 var1_1  var2_1 var3_1      id2 var1_2 var2_2 var3_2      id3 var1_3 etc

I have managed to create a dataset in long form by forming individual data sets for each id (using keep), then renaming the three variables in each dataset, to be the same across the datasets, and then appending them together. This being possible only because the data only involves 23 individuals.
I have looked at the reshape command but cannot see how it can be used with this arrangement. 
Is there another way to achieve this as the method used is not only tedious but clearly not easliy done as the number of individuals increase?

many thanks
Richard Hiscock
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index