Hi,
I'm trying to create a table of non-parametric test results (p-values). It seems like esttab/eststo need estimates stored and refuse to simply build a table of a few statistics:
Results:
I'm guessing there's likely an easier way to do this. Would someone mind pointing me in a better direction?
Thanks so much!
Lucas
I'm trying to create a table of non-parametric test results (p-values). It seems like esttab/eststo need estimates stored and refuse to simply build a table of a few statistics:
Code:
sysuse auto ksmirnov gear_ratio, by(foreign) eststo pooled, noe add(ks r(p)) ranksum gear_ratio, by(foreign) eststo pooled, noe add(rs r(p)) esttab, stat(ks rs)
Code:
. sysuse auto (1978 automobile data) . . . . ksmirnov gear_ratio, by(foreign) Two-sample Kolmogorov–Smirnov test for equality of distribution functions Smaller group D p-value --------------------------------------- Domestic 0.7308 0.000 Foreign 0.0000 1.000 Combined K-S 0.7308 0.000 Note: Ties exist in combined dataset; there are 36 unique values out of 74 observations. . . eststo pooled, noe add(ks r(p)) (e(ks) = 1.350e-07 added) last estimates not found r(301); . . ranksum gear_ratio, by(foreign) Two-sample Wilcoxon rank-sum (Mann–Whitney) test foreign | Obs Rank sum Expected -------------+--------------------------------- Domestic | 52 1453 1950 Foreign | 22 1322 825 -------------+--------------------------------- Combined | 74 2775 2775 Unadjusted variance 7150.00 Adjustment for ties -31.87 ---------- Adjusted variance 7118.13 H0: gear_r~o(foreign==Domestic) = gear_r~o(foreign==Foreign) z = -5.891 Prob > |z| = 0.0000 Exact prob = 0.0000 . . eststo pooled, noe add(rs r(p)) (e(rs) = 3.844e-09 added) last estimates not found r(301);
Thanks so much!
Lucas
Comment