Exercise 1-Frequency & Crosstabs

Point value:  5

Part 1: California Frequency and crosstabulation analysis.

Prior to attempting this exercise, install and open SPSS on your machine.
Read Almquist Chapt 1 and Section 2.2 to appreciate how SPSS works.
Familiarize yourself with Lab 1 (new Lab 1).
Look through the Public Policy Institute of California (PPIC) codebook for the June 2023 survey.
Locate, copy and save the text of the questions (not the response categories) for variables q32, q34, q54 and q75.
Download the data file for the PPIC June 2023 survey.  Ensure that the data file is locked.
Move the PPIC data file to your desktop.
Using SPSS open the PPIC data file.
Move the HW1 syntax file to your desktop.
Again using SPSS open the syntax file.
Your syntax should look like this:

*Homework 1 California Syntax*. 
*Runs on PPIC June 2023 Data*.
*Uses new MJ & Immig questions*.

*Frequency Analysis*.
*DVs*.
fre var q54.

fre var q52.

fre var q34.

*IVs*.
fre var gender. 

fre var q75.

*Frequency graphics.
fre var q54 q52 q34 gender q75
    /barchart percent.

*Crosstabulation*.
crosstabs tables =  q52 by gender q75 
    /cells = column count.

crosstabs tables =  q34 by gender q75
    /cells = column count.

Run the portions of syntax for a simple frequency analysis for q34, q52 and q54. Consult the valid percent column and report answers using a single decimal place.
Based on the SPSS frequency analysis output, answer the following questions:

Cal 1. What percent of the California sample answered that passing Proposition 64 was mostly a good thing?
Cal 2. What percent think the use of marijuana should be legal?
Cal 3. What percent are in favor of providing a legal path to citizenship for undocumented immigrants?
Cal 4. What is the most common response to the political orientation question?
Cal 5. What percent say they are very liberal?

The Crosstab portion of the syntax file instructs SPSS to compare men’s and women’s responses on q52 and Q34, as well as those of different political orientations on the same variables. Be sure to read Data Lab 2 before proceeding. Essentially, crosstabulation provides a side-by-side frequency distribution for subgroups of the sample, in this case along gender and ideological lines. The goal is to see not only whether the groups differ, but also whether being in a subgroup may predict attitudes. In this way we begin to consider relationships among variables.

Based on the cross-tabulation output, answer the following set of questions (Cal 6 – Cal 10):

After running the crosstabulation commands, answer the following:

Cal 6. Are women or men more supportive of legal marijuana?
Cal 7. Are women or men more supportive of providing a legal path to citizenship for the undocumented?
Cal 8. Among which political orientations are a majority of respondents opposed to legalized marijuana?
Cal 9. Among which substantive (disregard the ‘don’t knows’) orientations are a majority opposed to a pathway to citizenship for the undocumented?
Cal 10. Based on these results would you say gender or political orientation is more substantial predictor of attitudes toward immigration?

Please record your answers using the identifiers Cal 1-Cal 10.

Before moving on to Part 2 you may wish to save your syntax file under a distinctive name for use in subsequent exercises. Use your name and a topic identifier as a title, for example FletcherCalHW1. SPSS will add the .sps extension indicative of a syntax file. You are, of course, encouraged to explore the California data set further.

Part 2: Texas Frequency and Crosstab Analysis.

Access the UTexas codebook for December 2023. It is available on under the Data menu of the course website.
Browse through the questionnaire which is also available under the Data menu.
Locate, copy and save the text of the question (not the response categories) for variables q5 and q33.
Using SPSS, access the data for December 2023 Texas survey.
It is available on the Data menu. There are two ways to proceed from this point:

Route 1
Open a new syntax file in SPSS.
Write the syntax to run a frequency analysis for the variables q35, q31_1,gender_2 and libcon.
Rewrite the frequency analysis to include a graphics subcommand for bar charts.
Write the syntax to run crosstabulations for q35 and Q31_1 by gender and libcon.

Route 2
Download TexSyntax1 file from the Homework Exercise pageOpen the TexSyntax file. It contains the syntax described in Route 1

In either case, run the syntax and based on the output answer the following questions (B1-B10):

Tex 1. What is the least frequent response by Texans regarding the legal possession of marijuana?
Tex 2. What is the most common response?
Tex 3. Irrespective of the strength of opinion are Texans more likely to support or oppose a pathway to citizenship for illegal immigrants?
Tex 4. What is the most frequent self reported ideology among Texans?
Tex 5. What percent of Texans say they are extremely conservative?
Tex 6. Are Texas women or men more supportive of the unrestricted possession of small amounts of marijuana?
Tex 7. Are women or men in Texas more likely to support a pathway to citizenship illegal immigrants?
Tex 8. Among which political orientations in Texas are a majority opposed to the possession of marijuana under any circumstances?
Tex 9. Among which ideological orientations are a majority opposed to a pathway to citizenship for illegal immigrants?
Tex 10. Based on these results would you say gender or political orientation is a more substantial predictor of attitudes toward immigration?

As before please submit your answers using the identifiers used here, viz., Tex 1-Tex 10.

Before finishing your homework, you may wish to save your syntax file under a distinctive name for use in subsequent exercises. This should, of course, be different than the name used for the California syntax file. Nevertheless use your name and a topic identifier as a title, for example FletcherTexHW1.

You may, of course, also further explore the Texas data set.