Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Stringing an entire dataset


From   "Rio, Martin" <[email protected]>
To   [email protected]
Subject   st: Stringing an entire dataset
Date   Wed, 21 Jul 2004 15:20:20 -0400

I'm trying to stack several datasets. Each dataset has roughly 50 variables.
Some of these are string and some numeric. The source of my problem is that
any given variable could be numeric in one dataset and string in another.
When these two fields are stacked, Stata ignores the values of this variable
in the using dataset.

I thought that one way around this problem would be to string all variables
in the data, then stack them, and then destring those that I want to be
numeric, at the end. Can anyone think of code that would string all
variables that are not already string, keeping the same name variable names?
I have had no luck so far.

Thanks,
Martin
____________________
Mart�n Rio
Charles River Associates
Washington, DC
202.662.3957 (phone)
202.662.3910 (fax)
> ___________________________________________________
> This electronic message contains information from the consulting firm of
> Charles River Associates Inc., which may be confidential or privileged.
> The
> information is intended for the use of the individual or entity named
> above.
> If you are not the intended recipient, be aware that any disclosure,
> copying,
> distribution or use of the contents of this information is prohibited.  If
> you
> have received this electronic transmission in error, please notify us  by
> telephone (617 425-3582) or by e-mail ([email protected]) immediately.
>


*
*   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