Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
From | "Martin Weiss" <martin.weiss1@gmx.de> |
To | <statalist@hsphsun2.harvard.edu> |
Subject | AW: st: AW: easier way to write many matrix names |
Date | Tue, 13 Jul 2010 16:41:44 +0200 |
<> This accumulation technique is the key to many insidious problems, often in connection with -graph- commands. See it in perfection in NJC´s http://www.stata.com/support/faqs/data/distinctstrings.html HTH Martin -----Ursprüngliche Nachricht----- Von: owner-statalist@hsphsun2.harvard.edu [mailto:owner-statalist@hsphsun2.harvard.edu] Im Auftrag von Amanda Fu Gesendet: Dienstag, 13. Juli 2010 14:46 An: statalist@hsphsun2.harvard.edu Betreff: Re: st: AW: easier way to write many matrix names Dear Mr. Weiss, Thanks very much for your help! The accumulated command you provide works perfectly. I can use this logic on other similar problems I have encountered. This is cool! Best wishes, Amanda On Tue, Jul 13, 2010 at 3:13 AM, Martin Weiss <martin.weiss1@gmx.de> wrote: > You can certainly accumulate the command in a -local- beforehand: > > ************* > ma drop _all > forv i=1/29{ > loc name `name'A`i'\ > } > loc name `name'A30 > di in r "`name'" > ************* > HTH > Martin * * For searches and help try: * http://www.stata.com/help.cgi?search * http://www.stata.com/support/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/statalist/faq * http://www.ats.ucla.edu/stat/stata/