Dear all,

I am using -cointreg- from SSC in Stata 14. I have a panel dataset. However, I'm estimating FMOLS for each country/id.
The command - cointreg - saves its results in e(). The coefficient vector is stored in e(b). The FMOLS gives a long-run coefficient and intercept.


. cointreg gcf gds if id==1, est(fmols) eqtrend(0) vlag(1) kernel(qs) bmeth(andrews) nodivn

Cointegration regression (FMOLS):

VAR lag(user) = 1 Number of obs = 46
Kernel = qs R2 = .2646553
Bandwidth(andrews) = 1.5709 Adjusted R2 = .2479429
S.e. = 3.724559
Long run S.e. = 7.48136

------------------------------------------------------------------------------
gcf | Coef. Std. Err. z P>|z| [95% Conf. Interval]
-------------+----------------------------------------------------------------
gds | .9979715 .2491818 4.00 0.000 .5095841 1.486359
_cons | -1.91057 5.525475 -0.35 0.730 -12.7403 8.919162
------------------------------------------------------------------------------

. eret li

scalars:
e(N) = 46
e(r2) = .2646552666919184
e(r2_a) = .2479428863894621
e(rmse) = 3.724559297317706
e(lrse) = 7.481359939435503
e(rss) = 610.3830462063735
e(tss) = 830.0638034904455
e(eqtrend) = 0
e(xtrend) = 0
e(bwidth) = 1.5708772426484
e(vlag) = 1

macros:
e(cmd) : "cointreg"
e(cmdline) : "cointreg gcf gds if id==1, est(fmols) eqtrend(0) vlag(1) kernel(qs) bmeth(a.."
e(est) : "fmols"
e(vic) : "user"
e(bmeth) : "andrews"
e(kernel) : "qs"
e(properties) : "b V"
e(depvar) : "gcf"

matrices:
e(b) : 1 x 2
e(V) : 2 x 2

In order to export results to a spreadsheet, I use "runby" command.
I want to extract both the coefficients (gds and con in the above table) and its corresponding t-stats and p-values.
I would be grateful if you can kindly help me.

Thank you in advance.