Professional Documents
Culture Documents
Dosen Pengampu :
Anna Chadidjah, Dra., M.T.
Disusun Oleh :
Anis Khoirunnisa (140610160001)
Khodijah (140610160007)
Altriani Efendi (140610160039)
Eva Noer Cholis R (140610160041)
Alika Mlattipurnami (140610160093)
Kelas A
3. Each of 100 multiple-choice questions on an exam has four possible answers but one
correct response. For each question, a student randomly selects one response as the
answer.
a. Specify the distribution of the student’s number of correct answers on the exam.
Answer :
Distribusi yang cocok berdasarkan persoalan di atas adalah Distribusi Binomial,
karena peristiwa untuk memilih jawaban memiliki dua kategori yaitu correct or
uncorrect dari beberapa soal dengan n = 100 pertanyaan pilihan ganda dan p (peluang
menjawab benar) = ¼ = 0,25.
b. Based on the mean and standard deviation of that distribution, would it be surprising
if the student made at least 50 correct responses? Explain your reasoning.
Answer :
Mean= n x p = 100 x 0,25 = 25 and
standard deviation = √𝑛𝑝(1 − 𝑝) = √100(0.25)(1 − 0.25) = 4,33
Untuk mengetahui apakah mungkin terdapat siswa yang menjawab 50 soal dengan
benar maka perlu dihitung standar deviasi dari 50 soal yang benar :
𝑋−𝜇 50−25
z= = = 5.8
𝜎 4.33
Dari hasil perhitungan tersebut dapat disimpulkan bahwa akan mengejutkan apabila
terdapat siswa yang menjawab 50 soal dengan benar karena rata-rata jawaban benar
hanya sebanyak 25 dari 100 soal serta dilihat dari standar deviasi untuk 50 jawaban
benar lebih besar daripada standar deviasi untuk rata-rata 25 jawaban benar.
4. A coin is flipped twice. Let Y = number of heads obtained, when the probability of a head
for a flip equals π.
a. Assuming π = 0.50, specify the probabilities for the possible values for Y and find the
distribution’s mean and standard deviation.
Answer :
Y menyatakan kejadian munculnya gambar (head), dimana Y berdistribusi Binomial
Y~B(n,π)
n (frekuensi kejadian) = 2
π (peluang muncul gambar) = 0.50
𝑛
𝑃(𝑌 = 𝑦) = (𝑦) 𝜋 𝑦 (1 − 𝜋)𝑛−𝑦
2
𝑃(𝑌 = 0) = ( ) 0.500 (1 − 0.50)2−0 = 0.25
0
2
𝑃(𝑌 = 1) = ( ) 0.501 (1 − 0.50)2−1 = 0.50
1
2
𝑃(𝑌 = 2) = ( ) 0.502 (1 − 0.50)2−2 = 0.25
2
b. Find the binomial probabilities for Y when π equals (i) 0.60 , (ii) 0.40
(i) When π =0.60
Answer :
𝑛
π =0.60 ; n = 2 ; 𝑃(𝑌 = 𝑦) = (𝑦) 𝜋 𝑦 (1 − 𝜋)𝑛−𝑦
2
Y={AA} 𝑃(𝑌 = 0) = ( ) 0.600 (1 − 0.60)2−0 = 0.16
0
2
Y={AG,GA} 𝑃(𝑌 = 1) = ( ) 0.601 (1 − 0.60)2−1 = 0.48
1
2
Y={GG} 𝑃(𝑌 = 2) = ( ) 0.602 (1 − 0.60)2−2 = 0.36
2
(ii) When π =0.40
Answer :
𝑛
π =0.40 ; n = 2 ; 𝑃(𝑌 = 𝑦) = (𝑦) 𝜋 𝑦 (1 − 𝜋)𝑛−𝑦
2
Y={AA} 𝑃(𝑌 = 0) = ( ) 0.400 (1 − 0.40)2−0 = 0.36
0
2
Y={AG,GA} 𝑃(𝑌 = 1) = ( ) 0.401 (1 − 0.40)2−1 = 0.48
1
2
Y={GG} 𝑃(𝑌 = 2) = ( ) 0.402 (1 − 0.40)2−2 = 0.16
2
c. Suppose you observe y = 1 and do not know π. Calculate and sketch the likelihood
function.
Answer :
Fungsi Likelihood
𝑙 = (𝜋|𝑦 = 1)
𝑙 = 2𝜋(1 − 𝜋)
Dimana 0 ≤ 𝜋 ≤ 1, saat membuat plot dari fungsi likelihood maka didapat 𝜋 =0.5
d. Using the plotted likelihood function from (c), show that the ML estimate of π equals
0.50.
Answer :
Karena penaksir maksimum likelihood memaksimalkan fungsi likelihood, dengan
cara melakukan diferensial terhadap parameternya kemudian hasil diferensiasi
tersebut disamadengankan nol maka dari bagian c dapat diketahui bahwa fungsi 𝑙 =
2𝜋(1 − 𝜋) mengambil nilai maksimumnya di 𝜋̂𝑀𝐿 = 0.50
5. Refer to the previous exercise. Suppose y = 0 in 2 flips. Find the ML estimate of π. Does
this estimate seem “reasonable”? Why? [The Bayesian estimator is an alternative one that
combines the sample data with your prior beliefs about the parameter value. It provides a
nonzero estimate of π, equaling (y +1)/(n + 2) when your prior belief is that π is equally
likely to be anywhere between 0 and 1.]
Answer :
Jika y = 0, maka fungsi likehood akan menjadi 𝑙(𝜋|𝑦 = 0) = (1 − 𝜋)2 . 𝜋̂ =
0 memaksimumkan fungsi likelihood tersebut. Jadi dari hasil perhitungan parameter
tersebut dapat memungkinkan untuk mendapatkan gambar saat pelemparan koin.
6. Genotypes AA, Aa, and aa occur with probabilities (π1, π2, π3). For n = 3 independent
observations, the observed frequencies are (n1, n2, n3).
a. Explain how you can determine n3 from knowing n1 and n2. Thus, the multinomial
distribution of (n1, n2, n3) is actually two-dimensional.
Answer :
Diketahui n = 3,
maka untuk mendapatkan n3:
n3 = 3 – n1 – n2
b. Show the set of all possible observations, (n1, n2, n3) with n = 3.
Answer :
Observasi yang akan muncul adalah (3, 0, 0), (2, 1, 0), (2, 0, 1), (1, 2, 0), (1, 1, 1), (1,
0, 2), (0, 3, 0), (0, 2, 1), (0, 1, 2), (0, 0, 3)
c. Suppose (π1, π2, π3) = (0.25, 0.50, 0.25). Find the multinomial probability that (n1, n2,
n3)(1,2,0).
Answer :
Distribusi Multinomial :
𝑛! 𝑛 𝑛 𝑛
P (n1, n2, n3) = (𝑛 𝜋1 1 𝜋2 2 𝜋3 3
1 !𝑛2 !𝑛3 !)
3!
= (1!2!0!) x (0.25)1 x (0.50)2 x (0.50)0
= 3 (0.25) (0.25)
= 0.1875
The multinomial probability that (n1, n2, n3)(1,2,0) is 0.1875
d. Refer to (c). What probability distribution does n1 alone have? Specify the values of
the sample size index and parameter for that distribution.
Answer :
Distribusi peluang n1 adalah binomial probability distribution dengan n = 3, dan
parameter 𝜋 = 0.25.
7. In his autobiography A Sort of Life, British author Graham Greene described a period of
severe mental depression during which he played Russian Roulette. This “game” consists
of putting a bullet in one of the six chambers of a pistol, spinning the chambers to select
one at random, and then firing the pistol once at one’s head.
a. Greene played this game six times, and was lucky that none of them resulted in a
bullet firing. Find the probability of this outcome.
Answer :
Diketahui :
n=6
peluru tembak= y = 0
gagal = 6
𝜋 = 1/6
= (5/6)6
= 0.3349
8. When the 2000 General Social Survey asked subjects whether they would be willing to
accept cuts in their standard of living to protect the environment, 344 of 1170 subjects
said “yes.”
a. Estimate the population proportion who would say “yes.”
Answer :
𝑛(𝑦𝑒𝑠) 344
p = 𝑛(𝑠𝑢𝑏𝑗𝑒𝑐𝑡) = 1170 = 0.294
= −14.093
P-value = 2 x P(Z < -14.093) < 0.0001 , sehingga
Kriteria Uji : Tolak H0 jika p-value < alpha, terima dalam hal lainnya.
Di lihat dari hasil perhitungan ternyata p-value < 𝛼 =0.01, artinya 𝐻0 ditolak.
Kesimpulan : Dengan taraf signifikan 99% dapat disimpulkan bahwa 𝐻0 ditolak yang
artinya bahwa proporsi populasi yang mengatakan “yes” tidak sama dengan 0.05 .
c. Construct and interpret a 99% confidence interval for the population proportion who
would say “yes.”
Answer :
Selang kepercayaan, dengan nilai 𝑍0.99
𝜋0 (1−𝜋0 ) 𝜋0 (1−𝜋0 )
𝜋0 − 𝑍0.005 √ ≤ 𝜋̂ ≤ 𝜋0 + 𝑍0.005 √
𝑛 𝑛
0.294(1−0.294) 0.294(1−0.294)
0.294 − 2.58√ 1170
≤ 𝜋̂ ≤ 0.294 − 2.58√ 1170
9. A sample of women suffering from excessive menstrual bleeding have been taking an
analgesic designed to diminish the effects. A new analgesic is claimed to provide greater
relief. After trying the new analgesic, 40 women reported greater relief with the standard
analgesic, and 60 reported greater relief with the new one.
a. Test the hypothesis that the probability of greater relief with the standard analgesic is
the same as the probability of greater relief with the new analgesic. Report and
interpret the P-value for the two-sided alternative. (Hint:Express the hypotheses in
terms of a single parameter. A test to compare matched-pairs responses in terms of
which is better is called a sign test.)
Answer :
𝜋0 = 0.5
𝜋̂ = 0.6
𝑛 = 100
𝐻0 : 𝜋0 = 0.5, artinya peluang pengobatan standar sama dengan peluang
pengobatan baru
𝐻1 : 𝜋0 ≠ 0.5, artinya tidak peluang pengobatan standar sama dengan peluang
pengobatan baru
𝛼 =0.01
Statistik Uji :
𝜋̂ − 𝜋0
𝑍=
√𝜋0 (1 − 𝜋0 )/𝑛
0.6−0.5
=
√0.5(1−0.5)/100
=2
P value = 2 X P(Z< 2) = 0.0455, sehingga
Kriteria Uji : Tolak H0 jika p-value < alpha, terima dalam hal lainnya.
Di lihat dari hasil perhitungan ternyata p-value > 𝛼 =0.01, artinya 𝐻0 diterima.
Kesimpulan : Dengan taraf signifikan 99% dapat disimpulkan bahwa 𝐻0 diterima
yang artinya bahwa peluang pengobatan standar sama dengan peluang pengobatan
baru.
b. Construct and interpret a 95% confidence interval for the probability of greater relief
with the new analgesic.
Answer :
Selang kepercayaan, dengan nilai 𝑍0.025
𝜋0 ± 𝑍0.025 √𝜋0 (1 − 𝜋0 )/𝑛
𝜋0 (1 − 𝜋0 )
𝜋0 − 𝑍0.025 √ ≤ 𝜋̂ ≤ 𝜋0 + 𝑍0.025 √𝜋0 (1 − 𝜋0 )/𝑛
𝑛
0.6(1−0.6) 0.6(1−0.6)
0.6 − 1.96√ ≤ 𝜋̂ ≤ 0.6 + 1.96√
100 100
10. Refer to the previous exercise. The researchers wanted a sufficiently large sample to be
able to estimate the probability of preferring the new analgesic to within 0.08, with
confidence 0.95. If the true probability is 0.75, how large a sample is needed to achieve
this accuracy? (Hint: For how large an n does a 95% confidence interval have margin of
error equal to about 0.08?)
Answer :
Margin error untuk proporsi = (koefisien konfiden) x (standar error dari p)
margin error yang dibutuhkan yaitu 0.08 dan peluang sebesar 0.75
Koefisien konfiden untuk nilai z pada tingkat signifikansi sebesar 95% adalah 1.96, maka
𝑝̂ (1 − 𝑝̂ )
𝑀𝑂𝐸 = 𝑧𝛼 x√
2 𝑛
0.75(1 − 0.75)
0.08 = 1.96 x√
𝑛
0.75(1 − 0.75)
= 1.665972511 ∙ 10−3
𝑛
𝑛 = 112.5
Maka jumlah sampel yang dibutuhkan untuk mendapat margin error sebesar 0.08 adalah
sebanyak 112.5 sampel atau jika dibulatkan menjadi 113 sampel.
11. When a recent General Social Survey asked 1158 American adults, “Do you believe in
Heaven?”, the proportion who answered yes was 0.86. Treating this as a random sample,
conduct statistical inference about the true proportion of American adults believing in
heaven. Summarize your analysis and interpret the results in a short report of about 200
words.
Answer :
Metode statistika inferens yang dipakai adalah penaksiran parameter interval
n = 1158
𝜋0 = 0,86
Penaksir interval dari 𝜋 adalah sebagai berikut.
𝜋0 ± 𝑍0.025 √𝜋0 (1 − 𝜋0 )/𝑛
𝜋0 (1 − 𝜋0 )
𝜋0 − 𝑍0.025 √ ≤ 𝜋̂ ≤ 𝜋0 + 𝑍0.025 √𝜋0 (1 − 𝜋0 )/𝑛
𝑛
12. To collect data in an introductory statistics course, recently I gave the students a
questionnaire. One question asked whether the student was a vegetarian. Of 25 students, 0
answered “yes”. They were not a random sample, but let us use these data to illustrate
inference for a proportion. (You may wish to refer to Section 1.4.1 on methods of
inference). Let π denote the population proportion who would say “yes”. Consider H0: π =
0.5 and Ha: π ≠ 0.50.
a. What happens when you try to conduct the “Wald test”, for which 𝑧 = (𝑝 −
𝑝(1−𝑝)
𝜋0 )/√[ ] uses the estimated standard error?
𝑛
Answer :
n = 25
y=0
0
𝑃̂= 25 = 0
𝑆𝐸 = √𝑃̂(1 − 𝑃̂ )/𝑛
𝑆𝐸 = √0(1 − 0)/25
𝑆𝐸 = 0
𝑃̂ − 𝜋0
𝑍=
√𝑃̂(1 − 𝑃̂)/𝑛
𝑃̂ − 𝜋0
𝑍=
𝑆𝐸
0 − 0.5
𝑍=
0
𝑍 = −∞
Jadi dengan demikian dapat disimpulkan bahwa hasil standar eror yang diperoleh
adalah sebesar 0 dan statistic z sama dengan −∞.
b. find the 95% “Wald confidence interval” (1.3) for π. Is it believeable? (When the
observation falls at the boundary of the sample space, often Wald methods do not
provide sensible answers).
Answer :
𝑃̂ − 𝜋0
𝑍=
√𝑃̂(1 − 𝑃̂)/𝑛
0 − 0.5
𝑍=
√0.5(1 − 0.5)/25
−0.5
𝑍=
0.1
𝑍 = −5
Didapat nilai p-value lebih kecil dari 0.0001
Untuk mengetahui besarnya nilai p-value yang didapat, maka rumusnya sebagai
berikut:
𝑛! 𝑛!
= 2 {𝑦!(𝑛−𝑦)!π0y(1- π0)n-y + [𝑛!𝑦!π0n (1- π0)0}
25! 25!
= 2 {0!(25−0)!0.50 0.525-0 + 25!0!0.525 0.50}
𝑃̂ − 𝜋0
𝑍=
√𝑃̂(1 − 𝑃̂)/𝑛
0 − 0.133
𝑍=
√0.133(1 − 0.133)/25
−0.133
𝑍=
0.0679
𝑍 = −1.96
Jadi, 𝜋0 adalah 0.133 yang memiliki nilai p-value sebesar 0.05 (terbukti benar)
=(1- 0.5)25
= (0.5)25
𝑛!
ℓ1(π) = 𝑦!(𝑛−𝑦)!πy(1- π)n-y
25!
=0!(25−0)! π0(1- π)25
=(1-π)25
𝑛! 𝑛!
= 2 {𝑦!(𝑛−𝑦)!π0y(1- π0)n-y + [𝑛!𝑦!π0n (1- π0)0}
25! 25!
= 2 {0!(25−0)!0.50 0.525-0 + 25!0!0.525 0.50}
= (0.926)25
𝑛!
ℓ1(π) = 𝑦!(𝑛−𝑦)!πy(1- π)n-y
25!
= 0!(25−0)! π0(1- π)25
= (1-π)25
Bedasarkan pada Likelihood ratio test: -2 log (ℓ0 / ℓ1 ) = -2 log [(0.926)25 / (1)] = 3.84
Didapat nilai p value lebih kecil dari 0.05 dengan menggunakan tabel Chi-square
Untuk mengetahui besarnya nilai p-value yang didapat, maka rumusnya sebagai
berikut:
𝑛! 𝑛!
= 2 {𝑦!(𝑛−𝑦)!π0y(1- π0)n-y + [𝑛!𝑦!π0n (1- π0)0}
25! 25!
= 2 {0!(25−0)! 0.0740 0.07425 + 0!(25−0)! 0.07425 0.0740}
14. Sections 1.4.4 and 1.4.5 found binomial P-values for a clinical trial with y = 9 successes
in 10 trials. Suppose instead y = 8. Using the binomial distribution shown in Table 1.2:
a. Find the P-value for (i) Ha:π > 0.50, (ii) Ha:π < 0.50.
Answer :
(i) P-value untuk H0: π > 0.5 = P(8) + P(9) + P (10) = 0.055
(ii) P-value untuk H0: π < 0.5 = ∑8𝑖=0 𝑃(𝑖) = 1 − 𝑃(9) − 𝑃(10) = 0.989
b. Find the mid P-value for (i) Ha:π > 0.50, (ii) Ha:π < 0.50.
Answer :
𝑃(8)
(i) Nilai tengah P-value untuk H0: π > 0.5 = + P(9) + P (10) = 0.033
2
𝑃(8)
(ii) Nilai tengah P-value untuk π < 0.5= ∑7𝑖=0 𝑃(𝑖) = 1 − = 1 − 𝑃(9) −
2
𝑃(8)
𝑃(10) + = 0.967
2
c. Why is the sum of the one-sided P-values greater than 1.0 for the ordinary P-value but
equal to 1.0 for the mid P-value?
Answer :
Kita dapat melihat untuk nilai p-value yang biasa satu sisi p-value= ∑10
𝑖=0 𝑃(𝑖) +
𝑃(8) = 1 + 𝑃(8) > 1. Tapi untuk nilai tengah p-value adalah ∑10
𝑖=0 𝑃(𝑖) = 1
15. If Y is a variate and c is a positive constant, then the standard deviation of the distribution
𝑌
of cY equals cσ(Y ). Suppose Y is a binomial variate, and let p = 𝑛.
𝜋(1−𝜋) ½
a. Based on the binomial standard deviation for Y , show that σ(p) = [ ] .
𝑛
Answer :
Berdasarkan standar deviasi untuk Y yang berdistribusi binomial, akan ditunjukkan
𝜋(1−𝜋) ½
bahwa σ(p) = [ ]
𝑛
µ = n𝜋
𝜎 2 = 𝑛𝜋(1 − 𝜋)
𝑛
L(π) = log[(𝑦) 𝜋 𝑦 (1 − 𝜋)𝑛−𝑦 ]
n!
L(π) = log [y!(n−y)! 𝜋 𝑦 (1 − 𝜋)𝑛−𝑦 ]
n!
L(π) = log [y!(n−y)!] + log(𝜋)𝑦 + log(1- 𝜋)(𝑛−𝑦)
n!
L(π) = log [y!(n−y)!] + y log(𝜋) + (n-y) log(1- 𝜋)
b. One can usually determine the point at which the maximum of a log likelihood L
occurs by solving the likelihood equation. This is the equation resulting from
differentiating L with respect to the parameter, and setting the derivative equal to
zero. Find the likelihood equation for the binomial distribution, and solve it to show
that the ML estimate equals p = y/n.
Answer :
y (1-p) = (n-y) p
y – yp = (np – yp)
y + yp = np + yp
yp = np + yp – y
p = (np + yp – y)/ y
p = np/y + p
np = y
p = y/n
p = (y/n) (Terbukti)
17. Suppose a researcher routinely conducts significance tests by rejecting H0 if the P-value
satisfies P ≤ 0.05. Suppose a test using a test statistic T and righttail probability for the P-
value has null distribution P(T = 0) = 0.30, P(T =3) = 0.62, and P(T = 9) = 0.08.
a. Show that with the usual P-value, the actual probability of type I error is 0 rather than
0.05.
Answer :
Saat T=0, p-value = P(T≥0) = 0.3+0.62+0.08 = 1. Saat T = 3, p-value =
P(T≥3)=0.62+0.08 = 0.7. saat T=9, p-value = P(T≥9) = 0.08. karena nilai p-value
selalu lebih besar dari 0.05, maka kita tidak akan pernah menolak Ho. Kita tidak akan
memiliki kekeliruan tipe 1, karena peluang kekeliruan tipe 1 adalah 0 (terbukti).
b. Show that with the mid P-value, the actual probability of type I error equals 0.08.
Answer :
Saat T=0, nilai tengah p-value = 0.3/2+0.62+0.08 = 0.85. Saat T = 3, nilai tengah p-
value = 0.62/2+0.08 = 0.39. saat T=9, nilai tengah p-value =0.08/2 = 0.04. sehingga
kita akan menolak Ho saat T=9 karena nilai tengah p-value = 0.04<0.05. maka
peluang kekeliruan tipe 1 adalah peluang T=9 yaitu 0.08 (terbukti).
c. Repeat (a) and (b) using P(T = 0) = 0.30, P(T = 3) = 0.66, and P(T =9) = 0.04. Note
that the test with mid P-value can be “conservative” [having actual P(type I error)
below the desired value] or “liberal” [having actual P(type I error) above the desired
value]. The test with the ordinary P-value cannot be liberal.
Answer :
Saat T=0, p-value = P(T≥0) = 0.3+0.66+0.04 = 1 dan nilai tengah p-value = 0.3/2 +
0.66 + 0.04 = 0.85. Saat T = 3, p-value = P(T≥3)=0.66+0.04 = 0.7 dan nilai tengah p-
value = 0.66/2 + 0.04 = 0.37 . saat T=9, p-value = P(T≥9) = 0.04 dan nilai tengah p-
value = 0.04/2 = 0.02. dengan nilai p-value biasa, kita menolak H0 saat T=9 karena
pada kasus ini p-value = 0.04 ≤ 0.05. maka peluang kekeliruan tipe 1 adalah peluang
T=9 yaitu sebesar 0.04. dengan nilai tengah p-value, kita menolak H0 saat T=9 karena
pada kasus nilai tengah p-value = 0.02 ≤ 0.05. sehingga peluang kekeliruan tipe 1
adalah peluang bahwa T=9 yaitu sebesar 0.04.
18. For a given sample proportion p, show that a value π0 for which the test statistic z = (p −
π0)/√[π0(1 − π0)/n] takes some fixed value z0 (such as 1.96) is a solution to the equation (1
+ z20/n)π20+ (−2p − z20/n)π0 + p2 = 0. Hence, using the formula x = [−b ±√(b2 − 4ac)]/2a
for solving the quadratic equation ax2 + bx + c = 0, obtain the limits for the 95%
confidence interval in Section 1.3.4 for the probability of success when a clinical trial has
nine successes in 10 trials.
Answer :
Diketahui:
p − π0
z0 =
√π0 (1 − π0 )/n
Dimana,
(p − π0 )2
z02 =
π0 (1 − π0 )/n
z02 π0 z02 π20
p2 − 2pπ0 + π20 = −
n n
z02 2 z02
(1 + ) π0 + (−2p − ) π0 + p2 = 0
n n
Maka,
2
z2 z2 z2
2p + n0 ± √(2p + n0 ) − 4p2 (1 + n0 )
π0 = 2
z02
2 (1 + n )