Presentation is loading. Please wait.

Presentation is loading. Please wait.

Visualising contingency table data Dongwen Luo, G. R. Wood, G. Jones.

Similar presentations


Presentation on theme: "Visualising contingency table data Dongwen Luo, G. R. Wood, G. Jones."— Presentation transcript:

1 Visualising contingency table data Dongwen Luo, G. R. Wood, G. Jones

2 Introduction: A contingency table is a cross-tabulation of categorical variables. When faced with contingency table data, it is useful to have a quick method for visualising the associated distributions. A geometric object and simplex method is useful for picturing the distributions within a contingency table. Based on a two-by-two contingency table as simple.

3 Objective: The primary aim of this article is to show how the distributions of a contingency table can be presented geometrically using the concept of Simplex.

4 Three distributions: Joint distribution Conditional distribution Marginal distribution This article pictures these three types in a simplex.

5 Simplex A popular method in linear algebra. Used in optimization problem. Starts by picking a vertex first. Then we look at the neighbors of this vertex. If there is a neighbor that gives a better solution with respect to the objective function (max/min), we pivot to that new vertex. We follow this procedure until we reach a vertex that none of its neighboring vertices will give a better solution. Therefore we reach the optimal solution.

6 How to present in a simplex? For a given contingency table, the joint distribution can be represented by weights on all vertices of the simplex. A conditional distribution by weights on vertices of a face of the simplex. A marginal distribution by weights on the faces containing the conditional distributions.

7 Attitude IncomeForAgainst Low258222 High263151 Example: Income level vs acceptance of genetic engineering of food (Australia-wide survey)

8 12Total 1 2 1.00 Notations for three distributions:

9 Geometry of the three distributions:

10 Tetrahedron: In geometry, it is a polyhedron composed of four triangular faces, three of which meet at each corner or vertex. It is the three-dimensional case of the more general concept of a Euclidean simplex. For any tetrahedron there exists a sphere (called the circumsphere) on which all four vertices lie.

11 points A, B, C and D Figure (a)

12 Figure 1

13 joint distribution Income and Attitude point J in the tetrahedron Table 3 Relative frequency and the conditional distribution of X2|X1 for the Australian survey data. Attitude IncomeForAgainstTotal Low0.28860.24830.5369 (0.5375)(0.4625) High0.29420.16890.4631 (0.6353)(0.3647) Total0.58280.41721.00 Figure 1

14 Conditional distribution: Figure 1

15 Marginal distribution: Since, J = 0.5369C1 +0.4631C2, the marginal distribution of Income, (0.5369, 0.4631), can be specialized now as weights 0.5369 and 0.4631 on C1 and C2 having resultant J. (For our example) Figure 1

16 Presentation of distributions by simplex: Joint Distribution Conditional Distribution Marginal Distribution by weights on all vertices of the simplex weights on vertices of a face of the simplex weights on the faces containing the conditional distributions.

17 Fienberg and Gilbert (1970) showed that the loci of all points corresponding to independence of rows and columns in a 2×2 table is a portion of a hyperbolic paraboloid in the tetrahedron, For a given sample size the further J is from the independence surface, the greater the dependence between X1 and X2.

18 For higher dimensions: The three distribution can be presented in a higher dimensional simplex. This simplex has as many vertices as cells of the table. For conditional distribution partitions all vertices of the simplex. The each partition set forms a face of the simplex. A distribution conditional on levels of the chosen variables appears as weights on vertices of the associated face. Marginal distribution is obtained by the weights of the faces of each partition.

19 Example: A 4x4 table with variables X1 and X2 The joint distribution is the weights on the sixteen vertices (4x4) of the simplex S15. For conditional, X2|X1, the vertices of S15 are partitioned into four sets of four using the levels of X1. Four faces of S15 are then constructed as convex hulls of each set of vertices. The distribution of X2 conditional upon a given level of X1 is weights on the vertices of the associated face. The marginal distribution of X1 is weights on the four faces.

20 Geometry of 4x4 table: A conditional distribution is a weighting of the vertices of a partition set. For example, a weighting on the vertices of the upper shaded simplex. The associated marginal distribution of the subset of variables is the weighting of the facial simplexes formed by the partition, shown here using shading. Figure 3

21 Conclusions: These ideas can be generalized to multi-way tables. Using geometrical concept and simplex, we can present the multi-way tables in a sphere form. This spherize form gives us very clear cut idea about the form of the distributions associated with tables. We can easily compare this approach to compare different types of models as well as for drawing inferences about the data.

22 Thank you


Download ppt "Visualising contingency table data Dongwen Luo, G. R. Wood, G. Jones."

Similar presentations


Ads by Google