Bookmark and Share

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

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

Re: st: keeping variable labels after -collapse-

From   daniel klein <>
Subject   Re: st: keeping variable labels after -collapse-
Date   Sun, 6 Jan 2013 18:09:21 +0100

I might be overlooking something here, but the question is/was about
_variable_ labels, not _value_ labels. As far as I see, -label save-
just saves and "restores" the latter. -uselabel- may be used, but it
seems more burdensome than the few lines of code Nick suggested.


The FAQ concerned dates to 2002 (revised 2003): there's a simple
question whether -label save- existed then. (I am away from my old

That said, the macro-based method has some uses. Kit's technique
presupposes that the variables have the same names before and after
-collapse-, and if that's so it solves the problem completely. But
once you start -collapse-ing to new variable names, you will need
something where you have more control.


On Sun, Jan 6, 2013 at 4:10 PM, Christopher Baum <> wrote:
> Ingenious, but somewhat unncessary, as Stata will do this for you:
> label save using
> replace...
> do
> will restore the labels.
> Kit
*   For searches and help try:

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