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

Re: st: Hello all (quesiton about generate newvar=real(oldvar))


From   "Renzo Comolli" <[email protected]>
To   <[email protected]>
Subject   Re: st: Hello all (quesiton about generate newvar=real(oldvar))
Date   Sat, 18 Sep 2004 11:38:02 -0400

What you are tring to do can be accomplished in two ways. The way you are
trying is

. generate hour2=real(hour)
. drop hour
. rename hour2 hour

Alternatively you can do it all with one command
. destring hour, replace


Best,
Renzo Comolli

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