Statalist The Stata Listserver


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: sts graph legend, reshape and value labels


From   "Emma Slaymaker" <[email protected]>
To   <[email protected]>
Subject   Re: st: sts graph legend, reshape and value labels
Date   Fri, 01 Jun 2007 11:22:25 +0100

Thanks Austin, you are quite right when you suggest that I could tame my
sts graph legend problem in the example by using a loop to generate
variables containing the survivor function in each category of the by()
variable instead of reshaping.  In fact my first solution was simpler
still- I used a loop to generate the legend entries I wanted and put
that into the sts graph command. 

And I quite accept Nick's point that reshape and collapse are very
general, which is a good thing.   I can see why retaining the labels
could be confusing for reshape long and collapse but.... I'm hard pushed
to think of an example where it would be wrong to ask for the value
label of the j variable to be attached to the new variables that result
when you reshape wide. That's probably just a lack of imagination on my
part!

The reason I'm fixed on reshape is because I often encounter similar
problems when working with large datasets pooled from many different
surveys.  I like to do things as fast as possible and often want my data
in a wide form for graphs.  Correct labelling is then somewhat tedious,
particularly for someone like me who lacks attention to detail!

Anyway, now I have three possible solutions to the problem so all I
need to do is decide which to inflict on the workshop participants.

Cheers,

Emma


*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index