Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
R を用いた検定(補講) (1) — Welch 検定 / Tests using R (su...
Search
Kenji Saito
PRO
November 30, 2024
Technology
0
25
R を用いた検定(補講) (1) — Welch 検定 / Tests using R (supplementary) (1) - Welch test
早稲田大学大学院経営管理研究科「企業データ分析」2024 冬のオンデマンド教材 第9回で使用したスライドです。
Kenji Saito
PRO
November 30, 2024
Tweet
Share
More Decks by Kenji Saito
See All by Kenji Saito
続・インクルーシブな社会へ / Continuing Towards an Inclusive Society
ks91
PRO
0
16
AGI (人工一般知能) と創る新しく奇妙な社会 / New and Stranger Society built with AGI
ks91
PRO
0
63
回帰分析/大規模言語モデルと統計 / Regression Analysis, Large Language Models and Statistics
ks91
PRO
0
68
多重比較/相関分析 / Multiple Comparison and Correlation Analysis
ks91
PRO
0
64
アカデミーキャンプ 2025冬「考えるのは奴らだ」 / Academy Camp 2025 Winter - Live and Let Think DAY 3
ks91
PRO
0
60
アカデミーキャンプ 2025冬「考えるのは奴らだ」 / Academy Camp 2025 Winter - Live and Let Think DAY 2
ks91
PRO
0
47
アカデミーキャンプ 2025冬「考えるのは奴らだ」 / Academy Camp 2025 Winter - Live and Let Think DAY 1
ks91
PRO
1
73
インクルーシブな社会へ / Toward an Inclusive Society
ks91
PRO
0
21
P 値と有意差/分散分析 / P-value, Significant Difference and Analysis of Variance
ks91
PRO
0
70
Other Decks in Technology
See All in Technology
コンピュータビジョンの社会実装について考えていたらゲームを作っていた話
takmin
1
570
Autonomous Database Serverless 技術詳細 / adb-s_technical_detail_jp
oracle4engineer
PRO
17
45k
実は強い 非ViTな画像認識モデル
tattaka
1
1.1k
CDKのコードを書く環境を作りました with Amazon Q
nobuhitomorioka
1
150
Apache Iceberg Case Study in LY Corporation
lycorptech_jp
PRO
0
260
ウォンテッドリーのデータパイプラインを支える ETL のための analytics, rds-exporter / analytics, rds-exporter for ETL to support Wantedly's data pipeline
unblee
0
110
MIMEと文字コードの闇
hirachan
2
1.4k
内製化を加速させるlaC活用術
nrinetcom
PRO
2
110
【内製開発Summit 2025】イオンスマートテクノロジーの内製化組織の作り方/In-house-development-summit-AST
aeonpeople
1
500
OPENLOGI Company Profile for engineer
hr01
1
20k
利用終了したドメイン名の最強終活〜観測環境を育てて、分析・供養している件〜 / The Ultimate End-of-Life Preparation for Discontinued Domain Names
nttcom
2
360
プロダクトエンジニア構想を立ち上げ、プロダクト志向な組織への成長を続けている話 / grow into a product-oriented organization
hiro_torii
1
340
Featured
See All Featured
Building Adaptive Systems
keathley
40
2.4k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
Fireside Chat
paigeccino
34
3.2k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
33
2.1k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
49
2.3k
The Power of CSS Pseudo Elements
geoffreycrofte
75
5.5k
Building a Modern Day E-commerce SEO Strategy
aleyda
38
7.1k
Why Our Code Smells
bkeepers
PRO
336
57k
Keith and Marios Guide to Fast Websites
keithpitt
411
22k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5.2k
Writing Fast Ruby
sferik
628
61k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
10
500
Transcript
Boxes and whiskers — generated by Stable Diffusion XL v1.0
2024 9 R ( ) (1) — Welch (WBS) 2024 9 R ( ) (1) — Welch — 2024-11 – p.1/10
https://speakerdeck.com/ks91/collections/corporate-data-analysis-2024-winter 2024 9 R ( ) (1) — Welch —
2024-11 – p.2/10
( 20 ) 1 • 2 R • 3 •
4 • 5 • 6 ( ) • 7 (1) • 8 (2) • 9 R ( ) (1) — Welch • 10 R ( ) (2) — χ2 11 R ( ) (1) — 12 R ( ) (2) — 13 GPT-4 14 GPT-4 15 ( ) LaTeX Overleaf 8 (12/16 ) / (2 ) OK / 2024 9 R ( ) (1) — Welch — 2024-11 – p.3/10
t Welch R t.test() Welch Welch 2024 9 R (
) (1) — Welch — 2024-11 – p.4/10
2 t ( ) (1/2) 2 ( ) xA −
xB (1) : (2) : σ ( ) σ sp sp = s2 A (nA − 1) + s2 B (nB − 1) nA + nB − 2 (R var() ) nA + nB − 2 t Welch A B (µA = µB ) A B (µA = µB ) 2024 9 R ( ) (1) — Welch — 2024-11 – p.5/10
2 t ( ) (2/2) xA − xB Student µA
= µB t = (xA − xB ) − (µA − µB ) sp 1 nA + 1 nB = xA − xB sp 1 nA + 1 nB (t ) t dfp = nA + nB − 2 t ( ) t0.05 (dfp ) t0.05 (dfp ) < |t| (P < 0.05) 2024 9 R ( ) (1) — Welch — 2024-11 – p.6/10
Welch t t = xA − xB s2 A nA
+ s2 B nB ( ) v . . . v ≈ ( s2 A nA + s2 B nB )2 s4 A n2 A (nA−1) + s4 B n2 B (nB−1) R 2024 9 R ( ) (1) — Welch — 2024-11 – p.7/10
( ) - (Shapiro-Wilk test) - (Anderson-Darling test for normality)
- (Kolmogorov-Smirnov test for normality) ( ) ( ) (Bartlett’s test for homogeneity of variances) 2024 9 R ( ) (1) — Welch — 2024-11 – p.8/10
.txt A /B g <- read.table(" .txt", header=T) colnames(g) <-
c(" ", " ") sampleA <- g$ sampleB <- g$ # ( ) shapiro.test(x=sampleA) shapiro.test(x=sampleB) # ( ) samples <- c(sampleA, sampleB) group_factor <- factor(rep(c("A", "B"), c(length(sampleA), length(sampleB)))) bartlett.test(formula=samples~group_factor) # Welch (t.test() ) ( Welch ) t.test(sampleA, sampleB) 2024 9 R ( ) (1) — Welch — 2024-11 – p.9/10
2024 9 R ( ) (1) — Welch — 2024-11
– p.10/10