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: How can I append tabout output in Excel using logout?


From   sara khan <sarakhanum84@googlemail.com>
To   statalist@hsphsun2.harvard.edu
Subject   st: How can I append tabout output in Excel using logout?
Date   Wed, 28 Apr 2010 10:28:44 +0100

Dear Statalisters

I am running a lot of tabstats and need to compare the output in one
Excel sheet. Is there a way of appending the output as there isn't an
append option for logout?

Many thanks,

Here is my code:

forv i=0/5 {
foreach y in male singlet{
forv s=0/1{
di "myga==`i' & `y'==`s'"
qui su bwtg if myga==`i' & intab1==1 & admit_ic==1 & bwtg<. & `y'
	if r(N)!=0{	
 logout, save("C:\data\do_files\mytab.txt")  excel replace: tabstat
bwtg if myga==`i' & intab1==1 & admit_ic==1 & bwtg<., stat(n mean
median p25 p75 min max ) by(`y') col(stat) f(%9.0g) notot nosep

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