Professional Documents
Culture Documents
Parametricmethods
Theyarebaseinmeans,standarddeviationsorprobabilities.
NonParametricTests TheNormaldistributionisnotalwaysappropriate
Tostudyvariableswithafewobservations,
Nonsymmetricaldistributions,or
Variablesthatcanhavemorethantwovalues
Introduction(contd) Categories(ranking),means,medians
Somenonparametricmethodsuserankingsenlugardelos
Whenthishappens,weuseotheranaylisismethods realvalues.
Nonparametricmethods Categoriesareusetocomparedata,morefortheirranking
thatfortheirsize.
Theyarenotbasedinthesameassumptionsthatparametricmethods,but Patient Glucose in blood (mg/dl)
alsohavesomeassumptions. 1 135
2 225
3 70
4 100
5 110
6 150
7 90
8 100
9 170
10 60
11 80
Categories(ranking),means,median Aremeanandmedianequals?
Rankedinascendingorder
Tousemeanandconfidenceintervalisadequate,thedistributionof
Patient Glucose in blood (mg/dl) Ranking valuesshouldbesymmetric.
10 60 1
Tothemedianandconfidenceintervalsareadequate,noneedfor
3 70 2
assumptions.
11 80 3
7 90 4
4 100 5
8 100 6
5 110 7
1 135 8
6 150 9
9 170 10
2 225 11
Aremeanandmedianequals? Nonparametricmethods
Situation Non-paramethric Paramethric
Usingtheorder(ranking)insteadoforiginalvalues,reducestheneed method methods
forassumptionsaboutthedistribution,thecalculationsaresimpler
One sample Wilcoxon signed Z statistic ( t test)
andfaster. rank test
Thedisadvantageisthattheoriginalvaluesarelost. Two indpendent Wilcoxon sum Z statistic for two
Thus,nonparametricmethodsareusedonlytotesthypotheses,not samples rank test independent
samples (t test)
forestimationpurposes. Two paired Wilcoxon signed Z-paired statistic
samples rank test (t-paired test)
7 90 4
theformof"bell"asNormal.
4 100 5
8 100 6
5 110 7
1 135 8
6 150 9
9 170 10
2 225 11
Dataofonesample Dataofonesample
Patient Glucose in blood Differences Rnking
Wilcoxonsignedranktestiscalculatebysixsteps: (mg/dl) with 100
mg/dl
1.Tocalculatethedifferencebetweeneachobservationandtheinterestvalue,100
10 60 -40 6
mg/dl.
3 70 -30 4
2.Youshouldexcludeanydifference=0.
11 80 -20 3
3.Toclassifyandorder(ranking)differencesbymagnitude,nottakenintoaccoun 7 90 -10 2
thesign. 4 100 0
4.Sumtherankingsofpositivedifferences. 8 100 0
5 110 10 1
5.Sumtherankingsofnegativedifferences.
1 135 35 5
6.SelectthemorelittlesumsandcallitT.
6 150 50 7
9 170 70 8
2 225 125 9
Twoindependentgroups Twoindependentgroups
30teenagerswithacuteapendicitis,weredistributed15to
underwenttraditionalapendicectomiaand15with Tocompatepostsurgicalpaininbothgroups,wecanuseWilcoxon
laparoscopicapedicectomia. ranksumtest.
Forbothgroups,weevaluatepostsurgicalpain. WedefinethenullhypothesisHo:thetwodistributionsoverlap.
Post-surgical pain Traditional Laparoscopy WedefinealternativehypothesisHi:thetwodistributionsarenot
None 1 3 overlap.
Slight 5 7
Moderate 5 4
Severe 4 1
Total 15 15
Twoindependentgroups Twoindependentgroups
Wilcoxonranksumtesthasthreesteps: Post-surgical pain Traditional Laparosco
py
Rankings
Weorderthevaluesinbothgroupsinascendantorder. None 1 1+
TocalculateTasthesumofrankingsofmoreshortsampleoroneoftwoif None 3 3
thesamplesizeisequal.
Slight 5 9+
TocompareTvalueinthecriticalvaluesofWilcoxonranksumtest.
Slight 7 15
Moderate 5 21+
Moderate 4 25
Severe 4 29+
Severe 1 30
Total 15 15
Twopairedgroups Twopairedgroups
Thetableshowhoursofimprovementgivenbytwoanalgesicsin12patients WithWilcoxonsignedranktest,itisnorequirementtheNormality,but
withrheumatoidarthritis. thedatashouldbesymmetricaltobothsidesofthemedian.
Totestthattheimprovementisthesamewithbothanalgesics,wecanuse
pairedttestorWilcoxonsignedrankingtest. Ho:differenceinmedians=0Hi=differenceinmedians 0
Withbothmethods,wecalculatethedifferenceofimprovementinhoursfor
eachpatient.Patient A Analgesic B Analgesic
Patient A Analgesic B Analgesic Difference Rankings
1 3.5 3.5 0
1 3.5 3.5
2 3.6 5.7 -2.1 8
2 3.6 5.7
3 2.6 2.9 -0.3 3
3 2.6 2.9
4 2.6 2.4 0.2 2
4 2.6 2.4
5 7.3 9.9 -2.6 10
5 7.3 9.9
6 3.4 3.3 0.1 1
6 3.4 3.3
7 14.9 16.7 -1.8 6
7 14.9 16.7
8 6.6 6.0 0.6 5
8 6.6 6.0
9 2.3 3.8 -1.5 4
9 2.3 3.8
10 2.0 4.0 -2.0 5
10 2.0 4.0
11 6.8 9.1 -2.3 7
11 6.8 9.1
12 8.5 26.9 -18.4 11
12 8.5 26.9
Twopairedgroups Spearmanscorrelationofranks
Tableandgraphicshowincidenceofcoloncancerand
WecalculatetheWilcoxonsignedranktestfordifferences,makingthefollowing:
averageofmeatintakepercapitain13countries.
1. Counthowmanydifferencesnonzero.
2. Orderthedifferencesbytheirmagnitude,withouttakeintoaccountthesign.
Countr Incidence colon Mean of intake of meat
3. Sumrankingsofpositivedifferences. y ca
1 10 1
4. Sumrankingsofnegativedifferences. 2 8 9
5. SelectthemoreshorofthetwosumsandcallitT.(Sumofnegativedifferences=59,sumof 3 11 5
positivedifferences=7,T=7). 4 12 5
5 22 33
6. ComparetheTvalueinthecriticalvaluestablesforWilcoxonsignedranktest.T=7,p<0.05.
6 67 37
7 73 32
8 48 8
9 37 41
10 31 12
11 21 29
12 17 3
13 3 1
Spearmanrankscorrelation Spearmanrankscorrelation
Itisappropiateformonotonicrelationships,nonlineal. Countr Incidence Mean of meat Ranking of Ranking of
y colon ca intake cancer meat intake
ItiscalculateatthesametimethatrsPearson,onlyusingtherankings. 1 10 1 3 1
Tocalculateit,weneedthreesteps: 2 8 9 2 7
Toorderthevaluesoffirstvariable, 3 11 5 4 5
Toorderthevaluesofsecondvariable, 4 12 5 5 4
ToapplytheformulaeofrsPearson,usingtherankingsinsteadoforiginalvalues. 5 22 33 8 11
6 67 37 12 12
7 73 32 13 10
8 48 8 11 6
9 37 41 10 13
10 31 12 9 8
11 21 29 7 9
12 17 3 6 3
13 3 1 1 2
Comparisonofmethods
Example Parametric method Non-parametric
method
Glucose in t test for one Wilcoxon signed rank
blood sample p>0.05 test, p>0.2