Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, statalist.org is already up and running.


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

Re: st: AW: easier way to write many matrix names


From   Amanda Fu <mandy.fu1@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: AW: easier way to write many matrix names
Date   Tue, 13 Jul 2010 08:46:13 -0400

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/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index