Вы находитесь на странице: 1из 11

1

HIERARCHICAL LOG-LINEAR ANALYSIS (DR SEE KI N HAI)


1. 2. 3. 4. 5. 6. 7. 8. An extension of chi-square test to analyze contingency tables of 3 or more variables. To determine which of the variables and their interactions best explain the observed frequencies. Variables and interactions are called [Models]. Goodness-of-fit test statistics are used to assess the degree of correspondence between the Model and the Data. Statistical significance indicates the Model fails to account totally for the observed frequencies. Statistical non-significance indicates the Model fits the observed frequencies If more than 1 Model fits the data, look for the Model that has the least variables and interactions and the simplest one as the preferred Model. Likelihood ratio chi-square is employed as the test statistics.

Assumptions (Not as critical as parametric methods) 1. Random Sampling. 2. Similar shape and variability across the distributions. 3. Independent sample. Example. Table below shows a 3-way contingency showing the relationship between Gender, Attitude Towards Science and Science Achievement. Attitude Towards Science High Low Margin totals 1. Enter the data into the [Data View] and [Variable View] Science Achievement High Low High Low Female 20 40 35 45 140 Gender Male 30 25 55 50 160 1 = High, 2 = Low 1 = Female, 2 = Male Margin Totals 50 65 90 95 300

2 2. Weight cases by [Frequency] Select [Data] then [Weight Cases..] to open the dialogue box. Move [Frequency] into the [Frequency Variable] box and select [Weight cases by] then [OK].

Now the [Weight On] is shown in the [Status Bar] below

3. Select [Analyze] then [Loglinear] and [Model Selection..] to open the dialogue box. Move [Attitude], [Achievement] and [Gender] into the [Factors] box then select [Define Range].

4. Enter [1] into the [Minimum] box and [2] into the [Maximum] box then select [Continue].

5. Now select [Attitude] and [Define range]

Enter [1] into [Minimum] and [2] into [Maximum] and repeat for [Achievement] and select [OK].

4 Interpreting the output Extensive output is revealed by this test. It is best you ignore all and examine only the final model. 1. Ignore all the following tables:

Likelihood ratio 2 for the saturated or full model is presented first = 0.000 and p =1.000 meaning the saturated model provides a perfect fit for the observed frequencies and is non-significant. The saturated model consists of : 3 main effects (Attitude, Achievement and Gender), 3 2-way interactions (Attitude*Achievement, Attitude*Gender and Achievement*Gender) and 1 3-way interaction (Attitude*Achievement*Gender)

The saturated model includes all components that they individually may or may not have contributed to explaining the variation in the observed data. Thus, it is necessary to delete components one by one to see if this makes the models fit worse. If it does this component of the model iss kept for the final model. SPSS 20 begin with full model then delete each effect in turn to determine which effects make the least significant change in the likelihood ratio chi-square.

7 2. You only examine this Final Model below: The best-fitting model is presented last. In this case, the interaction of Achievement*Gender and the main effect of Attitude. This model has likelihood ratio 2 =3.91, DF =3 and p = 0.271 (not significant) which means the observed data can be reproduced with these 2 effects of Achievement*Gender and main effect of Attitude.

This table provides the Frequency or counts for the data and expected frequency under this model. Residual= Observed Count Expected Count = 50.000 46.250 = 3.750.

2 statistics used for Goodness-of-fit: 1. Likelihood Ratio chi-square commonly used because it has the advantage of being linear so that 2 values can be added or subtracted. 2. Pearson Chi-square.

To interpret the 2 effects of (a) Chi-square test of independence for Achievement and Gender, (b) Chi-square test for Goodness of fit for Attitude (Equal expected frequencies) run the analyses below. How to run (a) Chi-square test of independence for Achievement and Gender 1. Select [Analyze] then [Descriptive Statistics] to select [Crosstabs..] to open the dialogue box below. 2. Move [Achievement] into [Row] and [Gender] into [Column] box, then select [Statistics] to open the sub-dialogue box..[Crosstabs..]

3. Select [Chi-square] and [Continue] then click on [Cells] 4. Select [Observed], [Expected] and [Unstandardized] then [Continue] and [OK].

This table shows that more males (85) are in the High achievement than the females (55) i.e. 85/160 x 100% = 53.1% for Male and 55/140 x 100% =39.3% Female However, more females are in the Low achievement than the males

We can conclude that, there was a significant association between the science achievement and gender ( 2 = 5.75, DF =1 and p = 0.017)

How to run (b) Chi-square test for Goodness of fit for Attitude (Equal expected frequencies) 1. Select [Analyze] then [Non parametric Tests] , [Legacy Dialogs] and [Chi-Square] to open the dialogue box below. 2. Move [Attitude] into the [Test Variable List] and select [All categories equal] then click [OK]

10

This table shows that there are more students in the Low Attitude score than the High Attitude score. It is about 185/300 x 100% = 61.7% in High and 38.3% in Low attitude

There was a statistical significant difference between the observed and expected frequency for the 2 categories of Attitude (High and Low) towards science ( 2 = 16.33, DF =1, p =0.000)

Reporting the results A three-way frequency analysis was performed to develop a hierarchical linear model of Achievement and Attitude in Female and Male students. Backward elimination produced a model that include the main effect of Attitude and the interaction effect of Achievement and Gender. The model had a likelihood ratio 2 = 3.91, p = 0.27, indicating a good fit between the observed frequencies and the expected frequencies generated by the model. About 38% of the students had Low Attitude score. About 53% of the male students had High Achievement score as compared with about 39% of the female students.

11 COURSEWORK Determine the association between the variables in the table below by using the Log-Linear Analysis. Mental Ability High Low Margin Totals Maths Achievement Female High Low High Low 50 20 35 20 125 30 15 45 55 145 Gender Male 80 35 80 75 270 Margin Totals

Вам также может понравиться