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

st: save the value of a string variable into a macro


From   Jean-Benoit Hardouin <[email protected]>
To   [email protected]
Subject   st: save the value of a string variable into a macro
Date   Thu, 15 Jul 2004 20:03:39 +0200

I have a file like that :

. list depcom nomcom in 1/5

+-----------------------------+
| depcom nomcom |
|-----------------------------|
1. | 18001 Acheres |
2. | 18002 Ainay-le-Vieil |
3. | 18003 Les Aix-d'Angillon |
4. | 18004 Allogny |
5. | 18005 Allouis |
+-----------------------------+

Where depcom is an id. I want to save a specific values of the variable "nomcom" into a variable, for example, I want to obtain :
. di "`mymacro'"
Archeres

I don't find how to do that. Thank you for your help.

*******************************************
Jean-Benoit Hardouin
Regional Health Observatory
Orl�ans - France
Email : [email protected]
*******************************************


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