SPSS Workshop Chi-square g-o-f PDF

Title SPSS Workshop Chi-square g-o-f
Author Lauren Dowdeswell
Course Scientific Data and Analysis
Institution University of Chester
Pages 5
File Size 322.2 KB
File Type PDF
Total Downloads 100
Total Views 144

Summary

This is how to work out chi square goodness of fit ...


Description

SPSS workshop Chi-square goodness-of-fit test

The purpose of today’s workshop is to introduce you to the first inferential test of this module: Chi-square. Chi-square tests are very simple tests that we can use for research questions involving categorical data. They are commonly used to analyse questionnaire data, but are also useful for many animal behaviour related questions. In this workshop, you will learn how to run Chi-square tests in SPSS, using example data. You can then use the skills you have acquired to run the appropriate tests on the data you need to analyse for your assessed online workbook. You will learn how to run two different tests in two different ways, depending on how you organised your data (in its “raw” format or in form of a frequency table). You can use the video tutorials (see below for links) for today’s workshop to see how this is done (and some explanations about why, and how to interpret the outcomes), or follow the below written instructions. Example data sets are available on Moodle. To complete this workshop, do the following: 1. Run a Chi-square Goodness-of-fit test on the example data (eye colour), using both the “raw” data set and the frequency table 2. Create a “raw” and a frequency table data set from the DogTrust data you collected in the lecture. Run a Chi-square Goodness-of-fit test on both.

Link to video for Chi-squared goodness of fit test https://youtu.be/dlnm7txWCrM

Alternatively, use the written instructions below.

How to run Chi-square tests in SPSS 1. Chi-square Goodness-of-fit test This test can be used to investigate frequency distributions of single categorical variables. For example, you may be interested to find out whether there is an eye colour among subjects that is more common than others. Open the example data sets (eye_colour.sav and eye_colour_frequencies.sav) on Moodle. First, we will use eye_colour.sav to run the test. This has 13 rows of data for 13 subjects – it shows their eye colour as well as whether they were male or female. This data is in its “raw” form, i.e., not transformed into a frequency table. Familiarise yourself with the data set – check out the variable view to see how this has been set up. Now, to run the test, go to Analyse  Non-parametric tests  Legacy dialogs  Chi-square

In the pop-up window that appears, move the variable Eye_colour in to the Test Variable list. Make sure that, in the Expected values box, All categories are equal is selected. Then press Ok.

In the output window, you can now view the results of the test. Firstly, the Frequencies table shows you a summary of your data (a frequency table as you might have created it in Excel) showing how many times each category was Observed. Next to your observed frequencies, you can see the Expected count – this is what the data would look like if each category occurred equally often (what we call a uniform distribution). In this case, this is 4.3 – because you have 13 subjects and 3 categories of eye colour. 13 divided over 3 categories is 4.3. Below the contingency table, you can see the result of the test. The test statistic (Chi-square) is what is calculated by comparing your observed and expected frequencies as you have been shown in the lecture – look this up if you cannot remember. You are also shown the degrees of freedom (df) – these are calculated as the number of categories (here, 3) minus 1 – so your df = 2. Below that is the p-value (Asymp. Sig.). In this case, this is greater than 0.05. Think about what this means for your null hypothesis – do you accept or reject it? Therefore, is there or is there not a relationship between your observed and expected counts of eye colours? Accept null.

You should note the warning below your Chi-square test output – several of the cells have expected counts less than 5. This makes the test result less reliable and should be “fixed” by including more samples in the observation.

Next, we will use eye_colour_frequencies.sav to run the same test. Make sure you have the data set selected. Sometimes creating a data set in form of a frequency makes sense, especially if you have a very large sample size. To run the same test as above from such a frequency table data set, we first have to link the frequencies (counts of how many times each category occurred) to the categorical variables they describe (here, eye colour and sex). Otherwise, SPSS treats the variable frequency as separate from the other variables. To make this link, go to Data  Weight cases.

In the pop-up window that appears, select Weight cases by and then move the variable Frequencies into the field below that option. Press OK. Now you are ready to run the test as before through Analyse  Non-parametric statistics  Legacy dialogs  Chi-square. The result will be exactly the same as above....


Similar Free PDFs