asdocx: Export from Stata to Word, Excel, LaTeX & HTML › Forums › asdocx Forum › asdocx for exporting results of ttest | option rowappend › Reply To: asdocx for exporting results of ttest | option rowappend
Hello Lee,
Can you please provide the code you are using. From asdocx help file, I have tried the following code and it works fine.
sysuse auto, clear
asdocx ttest rep78==0, replace title(T-test results : mean == 0)
asdocx ttest price==0, rowappend
asdocx ttest mpg==0, rowappend
asdocx ttest turn==0, rowappend
asdocx ttest weight==0, rowappend
asdocx ttest length==0, rowappend
using rowappend
with by()
option
asdocx ttest mpg, by(foreign) replace
asdocx ttest mpg, by(foreign) rowappend
asdocx ttest price , by(foreign) rowappend
0 |1 2 3 4 5 6 7 8 9
----+-------------------------------------------------------------------------------------------
1 | obs1 obs2 Mean1 Mean2 dif St_Err t_value p_value
----+-------------------------------------------------------------------------------------------
2 |mpg by foreign: 0 1 52 22 19.827 24.773 -4.946 1.362 -3.65 0.001
3 |mpg by foreign: 0 1 52 22 19.827 24.773 -4.946 1.362 -3.65 0.001
4 |price by foreign: ~1 52 22 6072.423 6384.682 -312.259 754.449 -0.4 0.68
------------------------------------------------------------------------------------------------