Introduction To Sample Surveys - Lab 2 (Part 1) How To Enter Questionnaire Data in SPSS
Introduction To Sample Surveys - Lab 2 (Part 1) How To Enter Questionnaire Data in SPSS
In our “Attitudes towards the Library” survey data there are five questions. These questions
can be found on the last page of this lab. We will be entering our data so that each row will
represent a case (person) or questionnaire, and the columns will represent variables or
questions. Before we enter the data, we define our variables. This is a fairly time consuming
procedure, but if done correctly at first saves us a great deal of time later when we are
producing our output.
Q.1 Please tick the appropriate box, indicating your sex. Male
Female
In the Data Editor Window, click on Variable View at the bottom left hand corner of the
screen. Click on the first column in the first row, which is headed Name. In this cell fill in a
Variable Name for Question 1. This name must be no more than 8 characters, and cannot
have blank spaces. It will be the name given to this variable in the data set, and should be
something that you can easily identify. We will use Q1.
When you have typed in this name click on the next cell to the right. Some default settings
will appear in the other columns. We are happy to define our variable as Numeric, but we
would like 0 decimal places instead of 2. Make this change (in the fourth column).
Now click on the cell in the Label column. The Variable Label is the label which will appear
on your output and may or may not be the same as your variable name. You are not restricted
to 8 characters. For Question 1, the label sex is probably self explanatory.
Now click in the cell under Values and then on the button at the right of the cell. A box will
appear. Put 1 next to Value, then click next to Value Label and write male. Click on Add.
Now put in the Value 2 and the Value Label female. Click on Add, then OK. This ensures
that you can code your data as 1 and 2, but any output will use the words male and female.
Go to the second last column labelled Measure and change Scale to Nominal.
Our first variable is now defined. If you click on Data View at the bottom left hand corner of
the screen, you will see that the name at the top of column 1 is Q1.
Q.2 Please tick the box that best represents your view on the statement below:
Return to the Variable View window, go to row 2 and repeat the process for the second
variable. The second variable is a good example of the usefulness of the variable labels and
names. Your Variable Name which appears on the data screen, will be something short
which immediately reminds you of what it represents, such as Q2. However for your output,
you might like a more detailed label. You could choose to make your Variable Label the
actual statement The library offers good service.
Q.3 How many times have you visited the library during the last week?
Question 3 is a quantitative variable, and so we have no values to code. Just leave the Values
section blank. We could choose to make the Variable Label How many times did you visit in
last week. The Measure will remain as Scale.
Q.4 On your most recent visit to the library during the last week, which of the
following features of the library did you use?
(You may tick more than one box.)
Closed reserve
Study areas
Search facilities
Journal collections
Photocopiers
Question 4 is a multiple response question. There are two approaches to handling a multiple
response question. The most efficient way to code this question is to allocate a column for
each of the five options in question 4. Within each column, we have a dichotomous variable –
i.e. two possibilities only, Yes or No. This is known as the Multiple Dichotomy Method. Code
Yes as 1 and No as 0 for each of these variables. We could label the five columns respectively
closed reserve, study areas, search facilities, journal collections and photocopiers.
Note you can speed the process of defining the values by right clicking on the values cell for
the first question 4 variable, then copying the cell and pasting it in the rows for the remainder
of the question 4 variables. The Measure will be Nominal.
Q.5 From the following list of services provided by the Library choose two
which you feel are the most important. (Indicate each of your two choices with a
tick.)
Closed reserve
Study areas
Search facilities
Journal collections
Photocopiers
Once you have defined all your variables, you are ready to actually enter the data from the 12
completed questionnaires into the Data View window. Remember, each row represents a case
or questionnaire. So row one will have the numbers 1,4,2,1,0,0,0,0,2,4 in the first 10 columns.
Enter all the data from the twelve questionnaires. If you click on View>Value Labels, you
will be able to see the actual labels for the values you have entered. This toggles you between
the values and their labels.
The first step in the analysis of questionnaire data is to investigate each variable
separately.
2.1. We will first look at the single response categorical variables in the data set,
questions 1 and 2.
We might decide that a bar chart would display this variable more effectively. Click
on Graphs>Legacy Dialogs>Bar, click on Simple and select Summaries for groups
of cases. Click on Define. Select what you want for Bars represent, select Q1 for
Category Axis, and click on OK.
We would also like a frequency table, with counts and percentages for this variable.
Click on Analyze > Descriptive Statistics > Frequencies and select Q1 for
Variable[s]. Click on OK.
Repeat the above steps for question 2. What are the main features of the responses for
question 2?
None of the respondents strongly disagreed with the statement. 16.7% of the
respondents agreed, 41.7% of respondents were neutral, 33.3% of respondents
agreed, and 8.3% of respondents strongly agreed.
2.2. For Question 3, which is a quantitative variable, we can find a histogram. Click
on Graphs>Legacy Dialogs>Histogram. Select Q3 and click on OK. This output
also gives us the mean (average) number of visits. We could obtain more detailed
statistics about this variable using Analyze>Descriptive Statistics >Descriptives
Students visited the library about two times during the week on average. The
responses ranged from no visits during the week to five visits during the week. There
were no unusually large observations. (We could add that the distribution is
reasonably symmetric, but the clients may not find this information useful)
To produce frequencies for Question 4, click on Analyze > Multiple Response >
Frequencies. Select the multiple response set features used on last visit into Tables
for and Click OK. Look at the output. What is the difference between Percent of
Responses and Percent of Cases?
The percent of responses tells us the proportion of selections (ticks) that were for a
particular feature. The percent of cases tells us the proportion of the respondents
(people taking the survey) who selected a particular feature.
63.6% of the respondents stated that they used the closed reserve on their last visit.
2.4 To produce a Pie Graph for the Multiple Response Question, click on
Graphs>Legacy Dialogs>Pie. Select Summaries of Separate Variables (note: this
is different from previous page). Click on Define. Select the five variables from
question 4. Before selecting OK, answer the following questions:
The slices represent the proportions of selections that were for a particular item.
Why was it a good idea for us to code the variables as No=0 and not No=2?
If we choose No = 0, then the sum of the column will represent the number of
responses that choose “Yes”. If No = 2, then this meaning will be lost.
2.5. Question 5 is a multiple response question coded using the multiple response
method. We can follow the same method as for question 4, setting up our two
columns relating to Question 5 as a multiple response set. In this case however, our
Variables are coded as: Categories, and the Range is 1 through to 5. We can give our
multiple response set the name of importance and the label of features of most
importance and produce a frequency table. What information does this table give us
about the relative importance of the five listed features for this sample group?
It appears that the search facilities and journal collections are the most important;
both were selected by 50% of respondents. This is followed by (in order) study areas,
closed reserve and the photocopiers.
We noticed from our investigation of Question 2 that two out of the twelve people in
the survey disagreed with the statement “The library offers good service”. We might
like to investigate whether there are any differences between the opinions of males
and females. We are looking at the relationship between two categorical variables: Q1
and Q2.
Summarise any differences you observe between the answers to Question 2 of males
and females (carefully noting the categories of Q2 that correspond to each colour).
It appears that females have a more favourable opinion of the libraries service than
males. Then can be seen by noticing that all of the “Disagree” responses were made
by males, and more than half of the “Neutral” responses were from males, but all of
the “Strongly Agree” and more than half of the “Agree” responses were made by
females (and there were the same number of males and females in the sample).
2.7. We may like to investigate whether the number of visits in question 3 differed
between males and females. The variables involved are Question 3 which is
quantitative, and Question 1 which is categorical.
What differences do you observe between males and females with respect to their
responses to Q3?
By looking at the mean, we see that the females in the sample are using the library
more than the males on average, but also have more variation in the number of visits.
This conclusion is supported by the boxplot.
Click on Define Ranges. You have to enter in the minimum (1) and maximum (2) for
the Column variable. Click on Continue, then on Options. Notice you have the
choice of row, column or total percentages; and percentages based on cases or
responses. Choose Column Percentages and Percentages Based on Cases. Click on
Continue, then OK. Make sure you can really see where the output comes from,
particularly how any percentages have been calculated.
Summarise any differences you can see between the responses of males and females
to Q4.
It appears that, with the exception of the photocopier, the females in the sample used
each of the features of the library more than the males.
Selecting Cases
In many situations we would like to be able to select a subset of the data for analysis.
For example, question 4 is only relevant if the respondent has visited the library in the
last week. We might like to be able to produce tables and graphs based just on the
people who did visit the library in the last week.
Notice we are already on Select All Cases. Click on If condition is satisfied, then
click on the If button. Select Q3 >0. Click on Continue, then OK.
Look at the data screen. Notice that the row label for the third row (the person who
had not visited the library in the last week) has been crossed out.
Important Note:
Remember to go back and reselect all cases when you have finished analysing this
particular group.
Q.1 Please tick the appropriate box, indicating your sex. Male
Female
Q.2 Please tick the box that best represents your view on the statement below:
Q.3 How many times have you visited the library during the last week?
Q.4 On your most recent visit to the library during the last week, which of the
following features of the library did you use?
(You may tick more than one box.)
Closed reserve
Study areas
Search facilities
Journal collections
Photocopiers
Q.5 From the following list of services provided by the Library choose two which
you feel are the most important. (Indicate each of your two choices with a tick.)
Closed reserve
Study areas
Search facilities
Journal collections
Photocopiers