描述性統計學概念
醫學研究部生統小組
陳俊朋
Outline
• 統計名詞定義(p-value, SD, SE, CI)
• 資料型態
• 各種測量尺度對應的分析方法
• 常態分佈
• 描述性統計檢定
• Statistic chart
• ROC; Kappa
• SPSS操作步驟
2
What is p-value?
• 又稱為significance level :
– 以檢定統計量計算而得,用以衡量樣本資料接受或 拒絕虛無假設的程度。
• p值是機率,其值介於0與1之間
• 一般定義p < 0.05表示有統計上顯著差異
• e.g. p<0.05 or p<0.0001
3
95% Confidence Interval
• Interpretation of confidence interval
信賴區間(Confidence Intervals; CI):群體的正確數 值會落在這個數值範圍內。
95% CI表示有95%的信心確定群體的正確數值會落
在這個數值範圍內。
當解讀信賴區間的時候,我們有興趣的是……
• 信賴區間有多寬?
寬區間代表估計並不精準;窄區間則代表精準估計
• 可以從中取得哪些臨床觀點?
上限與下限可讓我們評估哪些結果具有臨床重要性
4
95% Confidence Interval
• 一篇研究指出,骨關節炎病人接受諮詢,相較於傳統 照護,4個月後,體重下降的幅度比傳統照護顯著...
– 諮詢組: 1.11 kg (95% CI, 0.70~1.52 kg)
– 傳統照護組: 0.37 kg (95% CI, 0.02~0.72 kg)
– 兩組間,體重下降平均值差異達統計顯著水準 0.74 kg (95% CI, 0.20~1.28 kg) (P=0.007)
5
Standard Deviation / Standard Error
名詞 簡稱 公式 意義
Standard Deviation
SD 樣本各資料點
分布的離散或 變異情形
Standard Error SE 樣本平均值的
估計準確度
• 圖形比較
n
Annals of the rheumatic diseases, 2019, annrheumdis-2018-214400
6
• Discrete
e.g. Number of children
• Continuous
e.g. Height, Weight
• Ordinal
e.g. Pain severity
• Nominal
e.g. Race, Gender
Variable type
Quantitative (numerical values)
Qualitative
(code numerical values)
Data definition
7
Data type/Statistical method
Data type Two group Three group Correlation
Independent Paired Independent Continuous Continuous
-parametric Independent T- test
Paired T- test
ANOVA Pearson
correlation
-nonparametric Mann-Whitney U test
Wilcoxon signed-rank test
Kruskal-Wallis test
Spearman
rank correlation
Nominal Chi-square test/Fisher’s exact test
McNemar test
Chi-square test
8
Tests of Normality
• Normal distribution (Gaussian distribution)
• Mean=Median=Mode
Normal
Left-skew
Right-skew Mean<Median<Mode
Mean>Median>Mode 9
Mean / Median
• 平均數易受到極端值的影響
• 用Boxplot找出極端值
Oncotarget 5.22 (2014): 11168. 10
Boxplot
11
Hypothesis Testing
• Hypotheses
– Null hypothesis (H0)
– Alternative hypothesis (H1)
無差異 有差異
無差異 有差異
12
type I or type II error
• H0:減肥藥不具減重療效
• H1:減肥藥具有減重療效
13
Independent T-test
Independent variable: ESRD and control (Two groups)
Dependent variable :Age、BMI、SBP、DBP…. (Continuous)
J Renin Angiotensin Aldosterone Syst. 2015 Mar;16(1):203-10. 14
Mann-Whitney U test
• Independent variable: HM and Non-HM (Two groups)
• Dependent variable:Total Pringle clamping、Op time..(Continuous)
World Journal of Surgical Oncology (2017) 15:19415
Chi-square test/Fisher’s exact test
• Independent variable: Positive and Negative (Nominal)
• Dependent variable:Age group、Gender…. (Nominal)
Journal of neuro-oncology 140.1 (2018): 37-47.16
Paired T-test / Wilcoxon signed-rank
• Independent variable:Pre-intervention and Post-intervention (Paired)
• Dependent variable:BMI、SBP….(Continuous)
Midwifery 68 (2019): 39-4717
Kruskal-Wallis test/ ANOVA
• Independent variable:
Tocilizumab, Abatacept and Tofacitinib (Three groups)
• Dependent variable:Age,
Disease duration…(Continuous)
Annals of the rheumatic diseases, 2019, annrheumdis-2018-214400
18
組數超過兩組 -Post Hoc Tests
• p-value < 0.05; 若拒絕虛無假設表示至少有一組平均值不相等,
並非所有平均值均不相等
• 兩兩比較(pairwise comparison) :
– 3 組(A,B,C)比較: (A v.s. B)( A v.s. C) (B v.s.C)
– 4組比較 : 6種兩兩比較
• 至少一次檢定的p值小於0.05的機率 – 4組比較
• 常見post hoc比較法 – Bonferroni method – Scheffe method
– Least squares difference method (LSD) 1 (1 0.05) 6 0.26
1 (1 0.05) n
19
McNemar test
• 僅適用22 table
• 同一人前後測/兩種不同診斷工具
Statistical methods in medical research, 2017, 26.1: 142-154.
20
• Pearson correlation
– Normal distribution – Continuous
• Spearman rank correlation – Skewed distribution – Ordinal/ Continuous
Correlation
說明:(相關係數數值範圍為-1~1) 相關係數 相關程度
1 完全相關
0.7~0.99 高度相關
0.5~0.69 中度相關
0.25~0.49 低度相關
0~0.24 無相關
Scientific reports 7 (2017): 40055.
21
• Pearson correlation • Spearman rank correlation
Scatter plot
22
Dot plot
Table. (N=77)
eGFR≥60 (n=44) eGFR<60 (n=33) p value Hb 13.7 (12.5-15.0) 12.7 (10.9-13.5) 0.004**
Mann-Whitney U test, Median (IQR).
23
ROC curve
• Optimal cutoff
• Diagnostic test evaluation
• 離左上角最近的點
• sensitivity + specificity 最大的點
• 離對角線垂直距離最大的點
(這段長度又稱為Youden Index = sen+spe-1)pIP10.1
0 20 40 60 80 100
0 20 40 60 80 100
100-Specificity
Sensitivity
Sensitivity: 78.0 Specificity: 70.8 Criterion : >382.68
24
International journal of oral and maxillofacial surgery 47.6 (2018): 699-707.25
Kappa test
• 類別型資料,需測量兩次
– 評估兩位以上的醫護人員(或檢驗方法)診斷結果是否一致 – 評估同一位醫護人員(或檢驗方法)重複診斷結果是否一致
說明:(數值範圍為-1~1)
Kappa值 一致性程度
0.0~0.20 極低的吻合度(slight) 0.21~0.40 一般的吻合度(fair)
0.41~0.60 中等的吻合度(moderate) 0.61~0.80 高度的吻合度(substantial)
0.81~1 幾乎完全吻合(almost perfect)
26
Orthopaedic surgery 10.3 (2018): 212-217.
27
SPSS 操作 - 常態檢定
28
分析>描述性統計>探索
p<0.05 代表資料呈非常態分佈
SPSS 操作 - 卡方檢定
29
分析>描述性統計>交叉表
SPSS 操作 - 卡方檢定
30
Table.
Non-HD (n=65)
HD
(n=35) Pvalue
Gender 0.053
F 29 (44.6%) 8 (22.9%) M 36 (55.4%) 27 (77.1%) Chi-square test.
SPSS 操作 - 相關
31
分析>相關>雙變數
Pearson 用於資料呈常態分佈
Spearman 用於資料呈非常態分佈
32
SPSS 操作 - 相關
Table. N=100
VO2max
rs p
Age -0.136 0.179
Weight -0.288 0.004**
Spearman's rho Coefficient.
SPSS 操作 - 兩組獨立樣本 ( 常態 )
33
分析>比較平均數法>獨立樣本T檢定
SPSS 操作 - 兩組獨立樣本 ( 常態 )
34
SPSS 操作 - 兩組獨立樣本 ( 非常態 )
35
分析>無母數檢定>歷史對話記錄>2個獨立樣本
SPSS 操作 - 三組獨立樣本 ( 常態 )
36
分析>比較平均數法>單因子變異數分析
SPSS 操作 - 三組獨立樣本 ( 常態 )
37
p>0.05 三組變異數無差異(同質性)
SPSS 操作 - 三組獨立樣本 ( 非常態 )
38
分析>無母數檢定>歷史對話記錄>K個獨立樣本
SPSS 操作 - 前後測比較 ( 常態 )
39
分析>比較平均數法>成對樣本T檢定
SPSS 操作 - 前後測比較 ( 非常態 )
40
分析>無母數檢定>歷史對話記錄>2個相關樣本
SPSS 操作 - 前後測比較 ( 非常態 )
41