Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: Cross Tabulation with more than 2 variables


From   Christoph Engel <[email protected]>
To   [email protected]
Subject   st: Cross Tabulation with more than 2 variables
Date   Mon, 22 Aug 2011 12:56:30 +0200

Dear readers of Statalist,

Maybe I just have not found the right command, or the right keyword. But since I frequently encountered the problem, I hope someone might point me to a convenient solution. I want to do cross tabulation for more than 2 variables.

This time, I have summary data about papers that I cannot include in a meta-study. There is a list of 10 reasons why I had to exclude them. Some papers are excluded for more than one reason. I have dummy coded these reasons. I therefore have a dataset of the following form

                    r1    r2    r3    ...    r10

study1        0    1    0    ...        0
study2        1    0    1               0
study3        0    0    1               1

I want to generate a table that looks like this

                    r1    r2    r3    ...    r10
r1                5      0    2            0
r2                2      4    0            0
...

I thus want to say, how often a study had to be excluded for reason 1 alone, or because it simultaneously suffered from reason 1 and reason 10 (or any other reason).

Is there a good way to do this? In principle, corr needs this information, but you do not get sums. tab2 provides the information, but does not collect it in one table.

Any help would be highly appreciated.

Best

Christoph Engel

--
_________________________________________________________________
Prof. Dr. Christoph Engel
Max-Planck-Institut zur
Erforschung von Gemeinschaftsgütern
Max Planck Institute for Research on Collective Goods
Kurt-Schumacher-Strasse 10
D 53113 Bonn
Tel. +49/228/91416-10
Fax +49/228/91416-11
e-mail: [email protected]
http://www.coll.mpg.de
http://www.coll.mpg.de/engel.html
http://ideas.repec.org/e/pen22.html
http://papers.ssrn.com/sol3/cf_dev/AbsByAuth.cfm?per_id=251559
_________________________________________________________________

*
*   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/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index