These are writing assignments (2) for a graduate-level applied research methods statistics 1 class. Very easy, simple. Only one page, times new roman 12 font, double spaced. Must be knowledgeable in

Writing Assignment 6:

Multivariate Analysis

Due date: Monday, September 27, 6 a.m.

Purpose: This assignment applies your understanding of using line graphs, contingency tables, and bar charts to perform bivariate and multivariate analyses. It reinforces concepts and coding skills that help prepare you for the first paper assignment.

Knowledge: This exercise

  • Reinforces your understanding of line graphs, contingency tables, and bar charts

  • Tests your ability to run analyses using one and two independent variables

Skills: This exercise also

  • Uses Stata to create and label variables and to run bar charts or line graphs

  • Develops your ability to write about statistics

Task: It is the fourth day of your internship at the congressional campaign. Your supervisor wants a new analysis of public opinion, but this time she wants you to look at how public opinion has changed, using the GSS 1972-2018 data set. She also wants to know whether some groups favor the policy more than others and whether support is changing at different rates for different groups.

  • You can continue with a previous topic or choose a different one. Some possibilities

    • legalization of marijuana (grass),

    • capital punishment (cappun),

    • gun control (gunlaw),

    • same-sex marriage (marhomo),

    • abortion (any of the variables that start with ab),

    • birth control (pillok)

    • government spending preferences (any of the variables that start with nat),

    • confidence in various institutions (any variable that starts with con),

    • the acceptability of police hitting people (variables starting with pol),

    • political tolerance (whether members of unpopular/dangerous groups (atheists, communists, homosexuals, militarists, racists) should be able to teach college, give speeches, and have their books in the public library (the variables start with col, lib, and spk)]

    • various types of sex outside marriage.

  • Search GSS Data Explorer (https://gssdataexplorer.norc.org/ ) to search for variables and question wording.

    • Click on SEARCH VARIABLES

    • Put a variable name (e.g., cappun) or search term (e.g., death penalty) in the Keyword box.

    • Click on variable name to find exact question wording, to see what years the question was asked, and to see the absolute frequency who gave each response in each year. (The question wording is all you really need, but if you see that a question was only asked a couple of times, it’s probably not a good choice.)

  • Create a new version of the opinion variable.

    • Dichotomize it so that the value you are interested in is coded 100 and the other values are coded 0.

  • First, show the overall trend in the percentage of respondents giving your Yes response.

    • Use tab year DEPVAR, row nofreq to see the percentage who said Yes in each year.

      • You probably won’t include this table in your paper, but you will use it to find out the percentages in the first and last years, as well as the years with the highest and lowest percentages.

    • Use bysort year: egen pctvar = mean(DEPVAR) to generate a new variable that is the percentage who said Yes in each year.

    • Use twoway (line pctvar year) to create a line graph showing how opinion on this issue changed over time. Use appropriate titles and labels.

    • You can cut, paste, and edit from the lecture do-file.

  • Second, choose one or two independent variables that you think affect opinion on this topic.

    • Obvious choices include sex, race, age, education (educ), religion (use relig), religious attendance (attend), party identification (partyid), and liberalism-conservatism (polviews).

    • Make sure that you understand how each variable is coded.

    • If the independent variable has more than 3 or 4 values, recode it to something simpler (e.g., convert polviews into a variable with the values Liberal, Moderate, and Conservative).

  • Third, use contingency tables and bar charts to test whether those variables have an impact on the probability of saying Yes.

    • Think carefully about whether to ask for row or column percentages in your contingency tables.

    • Make sure that the crosstabs and bar charts show consistent patterns.

  • Fourth, show the trend in the percentage of respondents giving your Yes response for each sub-group (e.g., for Liberals, Moderates, and Conservatives).

    • Use bysort year indvar: egen pctvar = mean(DEPVAR) to calculate the percentage of each group who said Yes in each year.

      • Note that this pctvar has to have a different name than the pctvar variable above.

    • Create a new variable for pctvar for each value of your independent variable.

      • For example: generate NOHS = edTOOpct if educ5==1

      • Create variable labels for new variables.

    • Using twoway (line pctvar1 year) (line pctvar2 year), etc., create a line graph showing how opinion on this issue changed for each value in your independent variable.

    • If sex is your independent variable, you will have two lines – one for men and one for women. The pctvars will be Men and Women.

    • If a recoded version of polviews is your independent variable, you will have three lines – one each for Liberals, Moderates, and Conservatives.

Write approximately one page (double-spaced, 12-point font, in Word), plus tables and graphs.

  • In the first paragraph, briefly state what you are going to do (e.g., I am examining how public opinion on X changed over the past XX years, whether men or women were more likely to say Yes, and whether the gender gap widened or narrowed over time).

    • You might want to briefly present your expectations (e.g., I hypothesize that approval of premarital sex has increased steadily over the past four decades, that men were much more approving than women in the early years, but that the gender gap has shrunk as women’s approval has risen faster than men’s).

  • Briefly state how you are measuring your dependent variable. (What question were respondents answering? What does pctvar represent?)

  • Describe how opinion changed over this period. What percentage said Yes in the first and last years? Did that percentage rise or fall steadily or was the pattern more complex?

  • Describe how opinion changed over this period for two or more groups. How large were the differences in the first and last years? Did the gaps remain about the same size or did they steadily narrow, steadily widen, or fluctuate over time?

  • Save all your commands in a do-file and copy it into your Word document at the end of the paper as an appendix.

  • Insert your line graphs and bar charts in the text. Add your crosstabs close to where you discuss them or at the end of the paper but before the appendix.

Criteria: This is a low-stakes exercise, worth approximately 1% of your final grade, so it is primarily an opportunity to practice your understanding of this module. Writing assignments are worth 10 points. To get the full 10 points,

  • Create a line graph showing how overall opinion on your issue changed over time. Graph should have appropriate title and labels.

  • Create a contingency table and bar showing how your independent variable(s) affected the probability of saying Yes.

  • Create a line graph showing how opinion on your issue changed over time for two or more groups. Graph should have appropriate title and labels.

  • Appropriately describe trends overall and for your groups.

  • Provide an appropriate appendix.