Statalist


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

RE: st: RE: -foreach-, local macro, -split- command


From   David Torres <torresd@umich.edu>
To   statalist@hsphsun2.harvard.edu
Subject   RE: st: RE: -foreach-, local macro, -split- command
Date   Tue, 08 Sep 2009 18:31:59 -0400

The point, I think, is to get those several values stored in the single variable split into several variables so that the data can then be reshaped long and merged with other data. An easier, quicker command would be nice, but if I have to do it dirty, then so be it. This would, of course, require the creation of several subcommands in my loop to create "carrier" variables for my strings that can each be separately split and later renamed to denote a panel. Oh, it's ugly, to be sure.

But perhaps I can approach this another way. I have tried using the generate command within my loop, adding a stub to the local, but that seems somewhat more complicated than what I've discussed here so far.

David Torres
*
*   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   |   What's new   |   Site index