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]

st: multiple merging


From   Abhimanyu Arora <abhimanyu.arora1987@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   st: multiple merging
Date   Tue, 3 Apr 2012 00:22:24 +0200

Dear statalist
I have datasets which I need to merge into a single file. All files
have a (string) variable that uniquely identifies observations in the
files.
There are two user-written commands I found in the SSC—mergeall (Ryan
Knight) and nmerge(Michael N. Mitchell).
I am facing problems with both.

In the first case I get a type mismatch error even though I specify
the string option with force

In the second case I am unable to get my file names (except the first
file) in a macro.  I used fs(Nick Cox) get the file names in r(files).
Next I type in  gettoken first `r(files)' : `r(files)'

That shows the following error

_"filename1.dta invalid name

I tried using extended macro function to clean up the quotes but to no
avail. Could you please help?
Many thanks
Abhimanyu

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