Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Q SCI 381: Introduction to Probability and Statistics Winter 2022 Laboratory #5 (73 points) In Lab 5, we will use one of the datasets already

Q SCI 381: Introduction to Probability and Statistics

Winter 2022

Laboratory #5 (73 points)

In Lab 5, we will use one of the datasets already available in R/RStudio. Many datasets are preloaded in R/RStudio; to see these datasets, enter the following command:

data()

One of these datasets is called "precip," and it contains the average amount of rainfall, in inches, for 70 cities from the U.S. and Puerto Rico.

Load the dataset by entering the following command:

data(precip)

To see the data contained in precip, enter:

precip

To learn even more about this dataset (or any preloaded dataset in R/RStudio), you can enter a question mark before the name of the dataset in R/RStudio:

?precip

After loading in the precip dataset, you are now ready to complete the lab.

(1) Use R to calculate the mean, median, variance, and standard deviation of precip. Paste or enter your answers below. (8 points)

(2) Plot a histogram of the data contained in precip. Add appropriate x-axis and y-axis labels, a title, and a color of your choice. Paste your plot below. (10 points)

(3) Examine your histogram. There is no built-in function in R to estimate the mode; however, based on your histogram, what value do you expect the mode to be? (2 points)

(4) Values for g1 and g2 for the precip dataset are -0.29 and 1.69, respectively. Using g1 and g2, and information from (2) and (3), is the distribution of data in precip approximately normally distributed? Why or why not? (8 points)

(5) In the continental U.S., the mean annual rainfall is 30.2 inches. Consider the following claim:

Annual rainfall from the 70 cities in the precip dataset is the same as the mean from the continental U.S.

Construct null and alternative hypotheses given this claim, and state whether this is a right, left, or two-tailed test. (3 points)

(6) To test the claim from (5), we can use a one-sample t-test in R. In module 7, you learned to use the t.test function in R:

t.test(dataset, mu = hypothesized mean, alternative=c("test"))

in which "test" is:

"less" (for a left-tailed test)

"greater" (for a right-tailed test)

"two.sided" (for a two-tailed test)

Use t.test() to test the claim from (5). Paste your t.test code and output below. (4 points)

(7) Interpret your output from (6) using alpha = 0.05. What is the statistical decision and interpretation? (8 points)

(8) Now, consider this claim:

Annual rainfall from the 70 cities in the precip dataset is less than the mean from the continental U.S.

Construct null and alternative hypotheses given this claim, and state whether this is a right, left, or two-tailed test. (3 points)

(9) Test your claim in (8). Paste your code and output below. (4 points)

(10) Interpret your output from (9) using alpha = 0.05. What is the statistical decision and interpretation? (8 points)

(11) Finally, consider this claim:

Annual rainfall from the 70 cities in the precip dataset is greater than the mean from the continental U.S.

Construct null and alternative hypotheses given this claim, and state whether this is a right, left, or two-tailed test. (3 points)

(12) Test your claim in (11). Paste your code and output below. (4 points)

(13) Interpret your output from (12) using alpha = 0.05. What is the statistical decision and interpretation? (8 points)

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

Step: 3

blur-text-image

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

Dynamical Systems With Applications Using MATLABĀ®

Authors: Stephen Lynch

2nd Edition

3319068202, 9783319068206

More Books

Students also viewed these Mathematics questions