Let's Get Started: Unit 2 LECTURE 6: Introduction To Hypothesis Testing, Type 1 & 2 Errors
Let's Get Started: Unit 2 LECTURE 6: Introduction To Hypothesis Testing, Type 1 & 2 Errors
Hi there,
Following are my notes for the lecture. These are my handwritten detailed notes. I felt that Prof. R
taught a lot more in the videos than he wrote in the slides. I tried to make them without any
mistakes and cover most of the video material.
I however DO NOT TAKE any responsibilty if you fail your exams following my notes. So please
check the actual lecture slides and videos if you suspect something is wrong.
The notes DO NOT CONTAIN solutions to any homework problems.Only the problems and
exercises solved in the videos are included in these notes.
'You feel it burn inside you. In your veins, muscles and bones. It rushes throught your body,
penerating your soul.... And finally you are free'
~ Excerpt from Diarrhea diaries
fon 72 jzlbtue +^W. h)e do not Lr-arne o {*t of, o1I the
boardi4g tr,mu but hle h'aw
1z
{.eroge W*e ', 24-2 wuvw ; sLandovd Dev0eHot'. 2.1 naivt*
2.WjLMA,: For wttMA boavdd4g vvt,eth"d hle co(lecbed the boavdingttmr,a
t . 56 Ltuited JUge+. , We do *ol Vr.aw a lr^t o& alt *he
56 boavctt4g tivrrter but rnle h,arne
q yniw ; Stondoyd Savdott% :
{v'evage trvrae : 15. 1.6 tnir,r.s
x
0 o
2-
r
cap,uo[
Y, Yr, Ya f ave idepertAe*n
]
Bure
t{,
rno} $nt
6,3
So the, f.*L rrvtodel,ting a,saur,,r,ptonr arle ds -$otfonx
Xt : tloo"rding -\ims + iil R2-r vnzlnod. +U?hk
Yt : Boordin6 {rme ill^ WILMA rnethod. {t^ALrt
*
X X.9 N (n, q")
Y ,9t N [-.9 , v,')
S e"act" ,twer
Ti".:o santplex &Ke inclepanc\enk
-(
p StattsHcal MocleL
We reca!,1 .fon+ e"atJ,s"el+ lWaV r,rrfi.at r"x. did s"qr.l.lltl- wqa ors ,k&otn*t,
Y i.s *wvaclexeA bv 4
E fP,i 0€o
)
uyt"knorac n3 L{r r le , 4,, %'
3ollw rn**a U
\, tar,lorgs {o O
f, : qondtdered
Any outcome covt be Fs : NitI be {hcjouni Pfirbabtti+h
q (xr Y)
drstriUuUi on pair O= R.X RX
(xry
ors po.tY
"f 1o,$1tbP)
) , As tcoV?t XrY lzrort, os'sunled +hAt
Alvqr- /
oire gousstavt X Al4ri Y qYz independeYtt
{r e&
,t1reR
{tu's, .is -
E= RX8, = RL
ie r-l
i"* [rtxt ty(tJ
prodJc+ 61 -thetroo PdtF q>e@r@)
6'e@r@)
6"1
h)so"vt.qald^a-:**aueshotLfUe',{owfuic-l'uYYJ#oYado%-lhq*rue
ir1 ,nh"at precrsef6
vroba,;l,it1- a#i U"tioru lazloyg- toe are yr.ot i*tawusbcA
9e ,ig (Sh;"r^,^lalthr. of 9.tt-attozt) ,u)4rt rr?',ic.lu :tr--gio* doea
Arol.
+* Vetrrlq +o.?
. Sgc-oyr,d, , *tta utloY rnp, {nqve. k'^ lated C'L(T u0e- axz wrb e*gw
1uesto.r,
enh; rtotvlir^q the. possrlat'tit5 {44At .t'< { 7- Soe*e*ullty
hfl^at l afi say irig is { knot"c e. c^n!+ betong tic t^e2tan' C.Tne
Buk *lner^e 'ts a pro,blaru, heve . koe see +?Lis heto t,r)
lde wurst notsfrtget {l^at Xn ond Y,
ore nandsm vartiable.s -tlnawrselveA .
{, .1,
Aeralrnds 61tu r-\, De?ends o7t rn
o.r{"a 51 and 6.
&o *t *1*tI a)
,lA
fl^** llt'al {ruz vatue { P = "j3 .*to^r hL% o* 1
b geh a, re.ali6ahoru * Z =-1"5 .€or'{lrat Aset- the dtstribution
)i
t0,11
4nd 'l |ttA 4^e E rs ved;yA belwcg,-
- k +io 7, \"9t*," Probahititg q57.
So Y = -1,5 'k a, pouibte. reolizarlr'on
if I {ar<< q57, prd"alarLt\ *
bznchvnatk-
^y
7'/.
-T -2r -fo 6 2t 2t E(
-z -z -Io I A 3
lvri,s is +he bo,t,rc puvtcilate : Yotrhcrre a \,\rolhe^;^ . As.surrte itg +nre ?ltVin,daka"
+o f^a tf +tae valua attarvted .rs a p*sltr" re,a\iz-aUa4.
6,9
FExorrtple Z
A, cocvt ts lnssed Bo drnea, Heods are obtaitpA I3 4tvra"ea . Can hle covl cU"td,o
tjaat the cnuT- tzS srg.rntftcarr.,tt6 tlvufarv l
f,ust Ji.ke *he prevfous exomple rr.re sotw /dnluire heve
Xr, Xr, Xa - Xrn,
^, Bertpl
Ttat soqo1.^ cottecfed h= Bo
C LT *e.\\s us
ln
Xn-P t-#
(d)
,ti (o, r)
h -+oo
p{t-p)
\" reperrt sqy (or suyr^e! s%) x,, lb
bo = .AZW =,42
uP!"rkt v\or^r hre sarcl p e (o,t) rn orcre.t {o test otrr hg{rotheux
r^'e httl q*,,^e beforeha,d th.attne .-i,-
ar {aiv -rs p = . 5
Tue onsNer
%
oiyr & Yts X alArrh4rr val,ue be{r^xm -L *o L tot+t4-
To understand this more thoroughly, lets see a weird example. Suppose I hypothesized that I
am a superhuman, in order to reject this hypothesis I devised a test. I will eat a whole
watermelon in one sitting. If I fail to do so my hypothesis will be rejected. I sat down and ate it
all. Can I now claim that the hypothesis is true and I am indeed a superhero. No, I can just claim
that I couldn't find any contradiction to my test, hence I am unable to reject my initial hypothesis.
This does not mean its true. It just means my test wasn't able to reject it
6.1
F Stabtg+tcaf Formulatoru ,J- ryprtt't sis Gs+ireq
g*
o/
e+ t ---+
+akegutosc.(
accordtvrg {o
lFe3eeo {he probtewu
o o
:i++ *y$ tmpovtant, to ,rndevstond, uvhat ,,Je o* ddryf &th"e *erntinotqy tho* hle \lae
}{o and ]h ore vtok syrnmektc . J{o is usua\ reloted {o stu}uE quo . Ie uruless pr5\ren
othern,&e , *rhl r^toutd hre sqy c. c.oivr ts %aised tr'6n'1+he beg,tnruing. Or a person ts
fnnocevtt -r.ryrttL pro\€n guiry. Or a. cWug.lan^s the some e$ed aA cL ptacek:o . Orc
\/\p, *tme inER ts svnatleythan equo&to 30. Ortoot?u methods' WitMftE RzF
^"t+tB
l'rarne om a\r€Yaqe the son .e trng .
We *est flo against flr . G ss stahlttohl4a its our job (r^xlhlhe hetp{d.qfa) {o-lm*<
fir evtdence against Ho . rde nnag t-rY,rtsr reject tto or{- mo1 VJhal be unabte +o
1^rc wttlsly
roject flo I but tlire & uufltt ne6r sag *Hat rnrc accepb Ho .
ig ,yhe,"testtry Ho againstr *{r rnre tn}sre uvrabte ! f."a.T*{h e,vddenceto
a"j** Ho, henea h)e atl€ unabte to reiecl tto . {,us effi does not mea?lhrs
fJuew tt (Ro) -to be true. we j*t wernettt o.tole *o yejeat tt
fie dcrto is orr\ used to dispror,e Ho tw {avout d H'
fu, E iw -the Ee Woittrrq ycrrnn hle con [and d.id qatlier) {orm hypollne,rrr irr,tr,'.:o \"]qyA
we should choose hyboth.rr^ @
H" : t>so Ho '. J.t( 30
AS H". ctss\rmes innocernc.e
Ht : -tl< 30
)ir : ,,{ >30
p.rorcn, olhey^x.se ie
uraJrt{,
u 9= D -{.to ts n of ve-)ecteA
1t V= t ) Ho ia ue.je&nA
Now V is i+set1 an tvr.dicq+orJunc{tsru 1l- , bec.q.rrse it *o,kc input & giws out l iro
on,.d'
g = ttr*=.:ffi,k4*tfl^ I
the t'elttry pvoced-rrre rnrttt be
aceording {o {he na*ure C +." tegt an-d the
y<tnd { vandom vaxr'a}o(er avrd &.te1uali{tea tnstde bu* th-rs i=the general rdea-
) Lels see {}ue codn exomple aqoin-
\Ne wovtted {o see if cotn- wqs uyr)oatsed trr ncrk
Ho : p = 172 , StttU 9uo, Cotvrshoutd be unbarsed/fnnortnt be.foveany ccnnyetevidencz
H' c'onbetrue
Atso notz. {hat we oresag,m6 tl^at ''o,.\ib. .^ ho !v.z h*'hoth%ia
{catn be- }aiv . i lrir"ot*r', bu"irlrlocent . A, a""t c'o-rtYu *f ^;-l<a'
a ptocebo 4ne wa) hla
jn4'"ua crur.lornu'tt$sr'-r". compella u^'{n ejt*ter
reject it olr woh fr.i".+ it.',6^ +t4i^ da- oltsUu,rXurshtoru one shoul-d kesP t,^,
{ne. back o+ ilrlL t^ i'"\4.
TvpE L evror
\yt?u L urrar dn o t*st { ,a 0J t"*d*
o(v ' eo '+K
Type 2 eT rsr
Tspe z evrar { atest tI t* a {uc*to'u
?v Ot R
s ,-+ P" [V= ol
6.13
But i{lis {s ?tot just 0. h^afi,or vrralhe,mahcltL comprutcahon
$ r ldf LQ,e hpn:
twe-{rrwc,ttons dqr & ?W axz c{e,frned
For eS.Lstg took o.b c{q, : T5'lae I ertur
By d.ff rnre knoN +l^at i{* -l{ae evr* o} ve.lechrtg hgpolhorir Ho nvhan it
Nqs tytdeerL true .
\r.ylut does it me-an {ort lt" {o be lrue ] rdett accovcti rrn *o orrv lorrnrilahor
s
t'1, vrteons g (fe the 'neaL PArcameberc) betongs to Oo
t$h"ew witt -tlne *est reject Ylo? t"lhen *he s+ahsHc +hof t^)s ca\c-r.rlaYs
wtth the heLp d ctota, grna \P = 1
8o !^,he cons4r t,tcL a pilcttctru I
o(q : fi [V=t] e€Oo
V 4r-)
1ni" Sovs i^= s op H' is aclua\ *ru a
Jt,t* g t's &st +olcl rlt tt reln L+eA
mopfd forn get Qo
?
v'P*tv=o]
4
UeOr
W
.tvus s&ys our t.h& s*6 4{o ts vw\ *rue
lrtbIIs tasfu b{d
us {hat Ho
,Wud pom canno? be vejecleA
ht* Or
JHese orlc o{-'{h e vno>L *,r,f," de4r'r"i#ovr* 6ne, uvt cane fl t^ri+l" 'hteltia
^t<-e-
?" v.)er 6{ a te*t V
-fi
Y
i"{ (r - pv te))
0e Or
6 .71
Noto r^M closely loolc at tae de{trr gl poh}ey Nofe tne orgurnent
ptt E F* (Q= o) &obob,rr.i! +fir* -the *est t's unqblelo reject Ho erre,n rruherr,
= in reol.i\ )'b'ts noL*rue ie O
Qiuen o € Or €, Or
-r,l
oo =---5; ^xrs
6"3,5
p ueuel x
Nor,r: thab vnrc terma S de{rtar*t*ovts Jels itnal\$ ansh}ev
dedtnecl sOme, or,uc qt erto,.r'
v pe t ;
--i-r,re
couy| dectores person qurt\ , t^shen ivr, rneaLld- he drd v.olr
Co mmil, any cvivne.
2 : Tl'te courtt sets *he Person f"a" , tthetr, ,lr,r, realih& t4u drd, comrnib
W" ttve gliv:y.,e.
Nor,u osk youvself rn:hat should {he cruv*s do tut orde-rc vternert 1o cornrvrit'
tFu f evrx ! . t1 .-that t^ror.r4- noonr. witt b4
Trre ovxsrd er i; s trrr ple LeL sverg o dy 30
b
lLl" dL -*te c^ir'^i^4lA
coyrvicbed nrroql,y'" {sre\ner,c this stratevX,r6 lnJttL
vtiote Le
Two &ided test 3 He.rre. r^re- clnfinz I 1ro a speci{lt Oo iw *te H, kufrot{tetU
Ho:0=Do Hr:&#go
Ue{s 6ee Vtor'n: -dnese det'n i{
3 lrt'ed +o tes+ if roilwra bettq : On e sr"ded "t{nzr ),r(wfunrA
1, Booxc{i.^g Mt t?rod'