Bookmark and Share

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


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

Re: st: Generating String variable containing `" & "'


From   Nick Cox <[email protected]>
To   "[email protected]" <[email protected]>
Subject   Re: st: Generating String variable containing `" & "'
Date   Mon, 6 Jan 2014 11:15:28 +0000

Your aim is misguided. A string variable cannot itself have string
labels (or numeric labels for that matter). You can label the numeric
values in -x- with the values of -y- as value labels. See

-findit labmask-

or

-findit sencode-

for possible solutions. Each application of -findit- will identifiy
download sources and documentation for the program in question.

Nick
[email protected]


On 6 January 2014 11:09, Dudekula, Anwar <[email protected]> wrote:
> Hello,
>
> This  seems to be an obvious question but somehow , I  am not able to get it .
>
> I have  two string variables   x  , y as follows
>
> Index         x                                 y
> 1              74170                COMPUTED TOMOGRAPHY, ABDOMEN; WITHOUT CONTRAST MATERIAL
> 2              73725        MAGNETIC RESONANCE ANGIOGRAPHY, LOWER EXTREMITY
> .
> .
> .
> .
> .
> .
> 1000
>
>
> I want to generate a string variable z , in the following format corresponding the observations 1, 2  :
>
> label define singleDXCCSlabel 74170  `"COMPUTED TOMOGRAPHY, ABDOMEN; WITHOUT CONTRAST MATERIAL"', modify
> label define singleDXCCSlabel 73725  `"MAGNETIC RESONANCE ANGIOGRAPHY, LOWER EXTREMITY"', modify
> .
> .
> .
> .
> .
>
>
> thank you very much for your time
>
> Thank you,
> Yours Sincerely,
> Anwar
>
>
>
>
> *
> *   For searches and help try:
> *   http://www.stata.com/help.cgi?search
> *   http://www.stata.com/support/faqs/resources/statalist-faq/
> *   http://www.ats.ucla.edu/stat/stata/
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


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