Export correlation table to Word with stars and significance level using asdoc

  • 4

Export correlation table to Word with stars and significance level using asdoc

Category:Uncategorized

The updated version of asdoc can now create a table of correlation with significance levels starred at different levels. The new version can be installed by typing the following line in Stata.


Installation of the new version

net install asdoc, from(http://fintechprofessor.com) replace


An Example

sysuse auto, clear
asdoc pwcorr price mpg rep78 headroom trunk weight length turn , star(all) replace nonum


Explanation

Just like with any other Stata command, we would write asdoc as a prefix to the Stata command. In this case, the Stata command is pwcorr which is followed by the variable names. After the comma, we added option nonum, star(all) and replace. These are explained bellow:

star(all) = This option is used to report stars to signfy significance at different levels. These are: ***

  1. *** to show significance at 1% or bellow
  2. ** to show significance at 5% or bellow
  3. * to show significance at 10% or bellow

nonum = Without using this option, asdoc will report numeric numbers as column headers

replace = This option replaces any existing file

You would be interested in this blog entry where I show several useful options of asdoc that can be used with correlation tables.




4 Comments

Amie

June 13, 2019at 6:33 am

THANK YOU for making it easy! I’ve been working with STATA for a year, and YOU just taught me how to do this!!!!

    Attaullah Shah

    June 13, 2019at 12:07 pm

    Amie
    Thank you for your feedback. I will appreciate if you cite asdoc in your research.

Qurat ul Ain

June 22, 2019at 3:26 pm

Thanks a lot. I Need only simple help. I am using asdoc stata package and want to make simple correlation instead of pwcorr.
I have seen some comments on blogs about pwcorr and this command also provide the facility to add star woth results. But I want to add star using corr command.
Please help me how I can add star while using corr command.

asdoc corr v1 v2 v3 
instead of 
asdoc pwcorr price mpg rep78 headroom trunk weight length turn , star(all)

Waiting for your kind response.

    Attaullah Shah

    June 22, 2019at 3:27 pm

    Stars are not possible with corr command. You have to use pwcorr command.

Leave a Reply

5 × four =