Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Answer questions 5 6 using R. Please submit your code in addition to your answers: 5. (R Companion, Ch 2, Exercise 2, 20 points) Dataset:

image text in transcribedimage text in transcribedimage text in transcribed
Answer questions 5 6 using R. Please submit your code in addition to your answers: 5. (R Companion, Ch 2, Exercise 2, 20 points) Dataset: gss. Variables: science_quiz, wordsum, wtss.) The late Carl Sagan once lamented: \"We live in a society exquisitely dependent on science and technology, in which hardly anyone knows anything about science and technology." Do the data support Sagan's pessimistic assessment? How does the public's grasp of scientic facts compare with other skills, such as word recognition and vocabulary? The gss dataset contains science_quiz, which was created from 10 questions testing respondents' knowledge of basic scientic facts. Values on science_quiz range from 0 (the respondent did not answer any of the questions correctly) to 10 (the respondent correctly answered all 10).19 GSSZOIZ also contains wordsum, which measures respondents' knowledge of the meanings of 10 words. Like science_quiz, wordsum ranged from 0 (the respondent did not know any of the words) to 10 (the respondent knew all 10 words). Science_quiz was created by summing the number of correct responses to the following questions (all are in truefalse format, except for earthsun): The center of the Earth is very hot (GSS variable, hotcore); It is the father's gene that decides whether the baby is a boy or a girl (boyorgrl); Electrons are smaller than atoms (electron); The universe began with a huge explosion (bigbang); The continents on which we live have been moving their locations for millions of years and will continue to move in the future (condrift); Human beings, as we know them today, developed from earlier species of animals (evolved); Does the Earth go around the Sun, or does the Sun go around the Earth? (earthsun); All radioactivity is man-made (radioact); Lasers work by focusing sound waves (lasers); Antibiotics kill viruses as well as bacteria (viruses). a. Run describe, freqC, and wtd.sd on science_quiz and wordsum. Fill in the following table: sciem'e_qni: wordsum Mean Median Mode Standard deviation b. Consider the following Sagan-esque statement: \"The public knows more about words than about science.\" Based on your results in part A, is this statement correct or incorrect? Explain your reasoning, making specic reference to the statistics you reported in part a c. Examine the frequency distributions for science_quiz and wordsum. According to conventional academic standards, scores of 9 or 10 on a 10-point quiz would be A's. What percentage of respondents would receive a grade of A on science_quiz? (Fill in the blank.) . What percentage of respondents would receive a grade of A on wordsum? (Fill in the blank.) d. Consider this statement: \"Science_quiz has a greater degree of dispersion than wordsum.\" Briey explain your answer: 6. (R Companion, Ch 3, Exercise 1, 20 points) (Dataset: gss. Variables: polviews, wtss.) The gss dataset contains polviews, a seven-category factor that measures political ideologythe extent to which individuals \"think of themselves as liberal or conservative.\" a. Run freq on gss$polviews, making sure to weight by gss$wtss. Add up the percentages of all liberals. The percentage of respondents who are either \"extremely liberal,\" \"liberal,\" or \"slightly liberal\" is: _% b. The percentage of \"moderates is equal to: -% c. Now add up the percentages of all conservatives. The percentage of respondents who are either \"slightly conservative,\" \"conservative,\" or \"extremely conservative\" is _% d. You are going to use cut2 to create a new variable, gss$polview3, that combines the three liberal categories, keeps moderates in their own category, and combines the three conservative categories. Cut2 will not work on factors, so use the as.numeric function to create a numeric version of gss$polviews. Name the numeric version gss$polviews.n. Run freq on gss$polviews.n (again weighting by gss$wtss). On gss$polviews.n, liberals have the following three numeric codes: On gss$polviews.n, moderates have the following numeric code: On gss$polviews.n, conservatives have the following three numeric codes e. Use cut2 to create a new variable, gss$polview3. Collapse gss$polviews.n's three liberal codes, keep moderates in their own category, and collapse the three conservative codes. Remember to apply cut2's plus-1 rule. Run freq on gss$polview3, weighting by gss$wtss. Record the percentages in each category (Fill in the blanks.): [1, 4)_ _ 4 _ [5, 8) f. Supply gss$polview3 with the following level names: "Liberal," "Moderate," and "Conservative." Use as.ordered to define gss$polview3 as an ordered factor. To check your work, run freq on gss$polview3. Run freq on gss$polview4 one more time, this time wrapping it inside printC. Copy and paste the frequency distribution from Table. Output.html to your word processor

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Introduction To Business Analytics

Authors: Troy Adair

1st Edition

1119132002, 9781119132004

More Books

Students also viewed these Mathematics questions

Question

=+d) Why does the no trend model from Exercise 40 no longer work?

Answered: 1 week ago