Home Forums ASDOC : Easy Publication Quality Tables in Stata Frequency tables along with inferential statistics for export into MS Word asdoc

Viewing 1 post (of 1 total)
  • Author
  • John Woods
    Post count: 118

    Thank you for developing the very useful asdoc command.

    I have attempted to post the following query on your online forum (https://fintechprofessor.com/forums/forum/asdoc/ ) but have been unable to troubleshoot an error message.

    I wish to produce frequency tables along with inferential statistics for export into MS Word, and would like the stats to appear immediately below the tabulated data. For example, the following code produces a table followed by chi-square stats in the Stata Results window, but only the table appears in the generated (or appended) Word document:

    asdoc tab gender q14_1, row chi2

    In the Stata results window but not the Word doc, the following output follows the table: Pearson chi2(4) = 21.7637 Pr = 0.000

    Is there coding I could use that would produce a Word doc with the frequency table followed by the chi-square stats (i.e., a .doc with output identical to the output displayed in the Results window)?

    (My intention is to produce a large number of similar tables using a foreach loop, so manual copying and pasting of the chi-square results to the Word doc would be inefficient.)

    Also, how might I display percentages with only one decimal point in the Word doc table? Adding the option ‘dec(1)’ to the code does not achieve this.

    With many thanks and best wishes,

    John Woods

Viewing 1 post (of 1 total)
  • You must be logged in to reply to this topic.