4. (a) Suppose we roll a dice 100 times and would like to determine if this dice is fair (null hypothesis). Say we compute the empirical mean and compare it to the mean of a fair dice. If we were to use the Z-test with significance level a = 0.05, how large or small does have to be for us to reject the null hypothesis? Express your answer as mathematical inequalities, and then use R to compute the answer numerically. Additional guidance: To use the Z-test we need to transform this into something that can be approximate by a normal distribution. If X₁,..., Xn are n = 100 fair dice rolls, then by the central limit theorem, Z:= 1 √n Xk - 3.5 σ 1 Here o is the standard deviation of one dice roll (calculate it!). The empirical Z is then xk-3.5 n ≈N(0, 1). k=1 Now, you should be able to use the Z-test... (b) Suppose we have a loaded dice where the probabilities are shown in the following table: x 1 2 3 4 5 6 P(X = x)| 1/4 1/8 1/8 1/8 1/8 1/4 Generate N = 105 experiments where each one consists of rolling this loaded dice 100 times. Of the N experiments, how often does the generated data fail the Z-test with significance value a = 0.05? (c) Same thing as the previous part with a different loaded dice: x 1 2 3 4 5 6 P(X = x)| 1/8 1/8 1/4 1/4 1/8 1/8 Report your results. (d) Compare your results for the two different loaded dice. Do they make intuitive sense and why?
4. (a) Suppose we roll a dice 100 times and would like to determine if this dice is fair (null hypothesis). Say we compute the empirical mean and compare it to the mean of a fair dice. If we were to use the Z-test with significance level a = 0.05, how large or small does have to be for us to reject the null hypothesis? Express your answer as mathematical inequalities, and then use R to compute the answer numerically. Additional guidance: To use the Z-test we need to transform this into something that can be approximate by a normal distribution. If X₁,..., Xn are n = 100 fair dice rolls, then by the central limit theorem, Z:= 1 √n Xk - 3.5 σ 1 Here o is the standard deviation of one dice roll (calculate it!). The empirical Z is then xk-3.5 n ≈N(0, 1). k=1 Now, you should be able to use the Z-test... (b) Suppose we have a loaded dice where the probabilities are shown in the following table: x 1 2 3 4 5 6 P(X = x)| 1/4 1/8 1/8 1/8 1/8 1/4 Generate N = 105 experiments where each one consists of rolling this loaded dice 100 times. Of the N experiments, how often does the generated data fail the Z-test with significance value a = 0.05? (c) Same thing as the previous part with a different loaded dice: x 1 2 3 4 5 6 P(X = x)| 1/8 1/8 1/4 1/4 1/8 1/8 Report your results. (d) Compare your results for the two different loaded dice. Do they make intuitive sense and why?
MATLAB: An Introduction with Applications
6th Edition
ISBN:9781119256830
Author:Amos Gilat
Publisher:Amos Gilat
Chapter1: Starting With Matlab
Section: Chapter Questions
Problem 1P
Related questions
Question
Please no written by hand solution and no img

Transcribed Image Text:4. (a) Suppose we roll a dice 100 times and would like to determine if this dice is fair (null
hypothesis). Say we compute the empirical mean and compare it to the mean of a
fair dice. If we were to use the Z-test with significance level a = 0.05, how large or
small does have to be for us to reject the null hypothesis? Express your answer as
mathematical inequalities, and then use R to compute the answer numerically.
Additional guidance: To use the Z-test we need to transform this into something that
can be approximate by a normal distribution. If X₁,..., Xn are n = 100 fair dice rolls,
then by the central limit theorem,
Z:=
n
1
X
P(X = x)
√n
k=1
Xk - 3.5
σ
Here is the standard deviation of one dice roll (calculate it!). The empirical Z is then
n
1
k=1
≈N (0, 1).
xk - 3.5
σ
Now, you should be able to use the Z-test...
(b) Suppose we have a loaded dice where the probabilities are shown in the following table:
1 2 3 4 5 6
1/4 1/8 1/8 1/8 1/8 1/4
Generate N = 105 experiments where each one consists of rolling this loaded dice 100
times. Of the N experiments, how often does the generated data fail the Z-test with
significance value a = 0.05?
(c) Same thing as the previous part with a different loaded dice:
X
1 2 3 4 5 6
P(X= x) 1/8 1/8 1/4 1/4 1/8 1/8
Report your results.
(d) Compare your results for the two different loaded dice. Do they make intuitive sense
and why?
Expert Solution

This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution!
Trending now
This is a popular solution!
Step by step
Solved in 5 steps with 12 images

Recommended textbooks for you

MATLAB: An Introduction with Applications
Statistics
ISBN:
9781119256830
Author:
Amos Gilat
Publisher:
John Wiley & Sons Inc

Probability and Statistics for Engineering and th…
Statistics
ISBN:
9781305251809
Author:
Jay L. Devore
Publisher:
Cengage Learning

Statistics for The Behavioral Sciences (MindTap C…
Statistics
ISBN:
9781305504912
Author:
Frederick J Gravetter, Larry B. Wallnau
Publisher:
Cengage Learning

MATLAB: An Introduction with Applications
Statistics
ISBN:
9781119256830
Author:
Amos Gilat
Publisher:
John Wiley & Sons Inc

Probability and Statistics for Engineering and th…
Statistics
ISBN:
9781305251809
Author:
Jay L. Devore
Publisher:
Cengage Learning

Statistics for The Behavioral Sciences (MindTap C…
Statistics
ISBN:
9781305504912
Author:
Frederick J Gravetter, Larry B. Wallnau
Publisher:
Cengage Learning

Elementary Statistics: Picturing the World (7th E…
Statistics
ISBN:
9780134683416
Author:
Ron Larson, Betsy Farber
Publisher:
PEARSON

The Basic Practice of Statistics
Statistics
ISBN:
9781319042578
Author:
David S. Moore, William I. Notz, Michael A. Fligner
Publisher:
W. H. Freeman

Introduction to the Practice of Statistics
Statistics
ISBN:
9781319013387
Author:
David S. Moore, George P. McCabe, Bruce A. Craig
Publisher:
W. H. Freeman