You should look at
-destring-
I hope this helps.
--David
At 10:25 PM 7/11/2004 -0800, Maoyong wrote:
Dear Friends:
I want to change the storage type of a variable in my dataset
from str to numerical. I have tried
recast int admit_major, force
recast2 int admit_major, force
but get the error message
admit_major: int invalid
r(109); t=0.01 22:18:01
The variable admit_major is string type and looks like:
1
3
4
5
[...]
David Kantor
Institute for Policy Studies
Johns Hopkins University
[email protected]
410-516-5404
*
* 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/