Thanks Martin and Maarten for the suggestion, it is working well.
Regards,
Kelvin
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Martin Weiss
Sent: Monday, 2 November 2009 6:15 PM
To: [email protected]
Subject: st: AW: how to produce a correlation matrix table with asterisks from Stata to LaTex
<>
*************
capt which estout
if _rc ssc inst estout
webuse abdata, clear
estpost correlate wage cap /*
*/ indoutpt w k, matrix
esttab ., not unstack compress noobs
*************
HTH
Martin
-----Ursprüngliche Nachricht-----
Von: [email protected]
[mailto:[email protected]] Im Auftrag von Kelvin Tan
Gesendet: Montag, 2. November 2009 08:24
An: [email protected]
Betreff: st: how to produce a correlation matrix table with asterisks from
Stata to LaTex
Dear All,
I would like to know if I can produce a correlation matrix table with
asterisks in Stata and export the table to LaTex. I have tried with both
-pwcorr- and -corrtex-. -pwcorr- does not produce a LaTex formatted
correlation table. -corrtex- can produce a Latex formatted correlation
matrix table but it does not produce asterisks (*** if p-value<0.001, **
if p-value<0.01, * if p-value<0.05) to indicate the different levels of
significance.
---Begin Example ----
webuse abdata
pwcorr wage cap indoutpt w k , star(0.001) sig
corrtex wage cap indoutpt w k , file(CorrTable) replace land sig dig(4)
---End Example ----
I would like to produce something looks like the following table and
hopefully this correlation matrix table can be transferred to LaTex
formatted table. Thanks in advance.
| wage cap indoutpt w k
-------------+---------------------------------------------
wage | 1.0000
cap | 0.0074 1.0000
indoutpt | 0.0112 -0.0224 1.0000
w | 0.9798* 0.0018 0.0247 1.0000
k | 0.0751* 0.7124*** 0.0601 0.0625 ** 1.0000
Regards,
Kelvin
*
* 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/
*
* 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/
*
* 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/