Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
From | Eric Booth <ebooth@ppri.tamu.edu> |
To | "<statalist@hsphsun2.harvard.edu>" <statalist@hsphsun2.harvard.edu> |
Subject | Re: st: tabout for multiple likert-scale questions |
Date | Sat, 25 Sep 2010 17:21:29 +0000 |
<> **************************! clear set obs 200 forval n = 1/5 { g Q`n' = 1+int((7-1+1)*runiform()) } gen question="Q1" **Q1** tabout question Q1 using table1.xls, replace cell(freq row) format(0c 0p) /// clab(Frequency Percent) ptotal(none) h1(| Likert Scale Questions) drop question **Q2 - Q5** forval n = 2/5 { preserve keep Q`n' gen question="Q`n'" tabout question Q`n' using table1.xls, append cell(freq row) format(0c 0p) /// ptotal(none) h1(nil) h2(nil) h3(nil) restore } **************************! - Eric __ Eric A. Booth Public Policy Research Institute Texas A&M University ebooth@ppri.tamu.edu Office: +979.845.6754 On Sep 25, 2010, at 3:19 AM, Vicki Livingstone wrote: > Hi all, > > I am running descriptives for a questionnaire that has many questions measured > on the same Likert scale. What I would like to output is a table where > the rows correspond to each question and the columns are the n(%) for > each category of response within the question. > > Using the following commands, I can output the results for an individual > question. > gen new=1 > tabout new Q1 using table1.xls, replace cell(freq row) format(0 0) > clab(Frequency Percent) > > Is there a way of including all Likert questions in the output? > > Many thanks in advance, > Vicki Livingstone > > > > > > * > * 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/