Statalist


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

RE: st: converting a local of variable names in string variables


From   "Nick Cox" <n.j.cox@durham.ac.uk>
To   <statalist@hsphsun2.harvard.edu>
Subject   RE: st: converting a local of variable names in string variables
Date   Tue, 26 Feb 2008 14:37:16 -0000

-string()- maps numbers to strings. Thus string(42) yields "42". 

-word(,)- extracts words from strings. Thus the argument and the result 
are both of string type. 

Nick 
n.j.cox@durham.ac.uk 

Johannes Geyer

I do not know why my code did not work but I guess I did something the 
function string() is not designed for. Instead I tried something
different 
with word() and that works perfectly:

*
*   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–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index