Viewing 2 posts - 1 through 2 (of 2 total)
• Author
Posts
• Ken Wang
Participant
Post count: 4

Hi, everyone. Recently I have run the following codes:

```sysuse auto.dta, clear
regress price mpg headroom trunk displacement
estimates save results, replace
clear
estimates use results
asdocx regress, replace ```

Stata returns an error message “no observations”. However, if you run regress, you can get all the information regarding the regression, regardless of data in the memory. Why does asdocx here fail to output the information?

Attaullah Shah
Moderator
Post count: 33

I have added support for stored estimates now. Instead of using regress, use `replay` to replay the stored estimates. Please update and try the following example

```asdocx_update
```

### Example of detailed regression

```sysuse auto.dta, clear
regress price mpg headroom trunk displacement
estimates save results, replace
clear
estimates use results
asdocx replay, replace save(detailed.html)```
Linear regression
Variables Coef. Std. Err. t-value p-value [95% Co Interval] Sig
mpg -124.512 75.153 -1.66 0.102 -274.438 25.414
headroom -789.532 471.188 -1.68 0.098 -1729.525 150.462 *
trunk 66.222 106.529 0.62 0.536 -146.298 278.742
displacement 11.935 4.884 2.44 0.017 2.191 21.678 **
Constant 7914.615 2701.779 2.93 0.005 2524.713 13304.518 ***
Mean dependent var SD dependent var .
R-squared Number of obs 74.000
F-test Prob > F 0.000
Akaike crit. (AIC) Bayesian crit. (BIC) 1386.274
Notes: *** p<.01, ** p<.05, * p<.1

### Example of nested regression

```sysuse auto.dta, clear
regress price mpg headroom trunk displacement
estimates save results, replace
clear
estimates use results
asdocx replay, replace save(Nested.html) nest```
Table: Regression results
(1)
Variables price
mpg -124.512
(75.153)