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
12
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
P 値と有意差/分散分析 / P-value, Significant Difference and Analysis of Variance
ks91
PRO
0
17
関連2群のt検定/独立2群のt検定 / Related 2-group t-test and independent 2-group t-test
ks91
PRO
0
47
A Guide to Paper Writing Support with Generative AI - A Joint Zemi
ks91
PRO
0
9
正規分布と簡単な統計理論/t分布と信頼区間 / Normal distribution, simple statistical theory, t-distribution and confidence intervals
ks91
PRO
0
42
じわじわ迫ってきている自動化社会 (その先にメタ・ネイチャー) / The Slowly Approaching Automated Society (and its beyond: Meta-Nature)
ks91
PRO
0
6
起こりうる誤った推論/平均・分散・標準偏差・自由度 / Possible false inferences, means, variances, standard deviations and degrees of freedom
ks91
PRO
0
57
LaTeX と Overleaf によるショートペーパー作成 / Short paper writing with LaTeX and Overleaf
ks91
PRO
0
23
R を用いた検定(補講) (2) — カイ二乗検定 / Tests using R (supplementary) (2) - Chi-squared test
ks91
PRO
0
13
R を用いた分析(補講) (1) — 重回帰分析 / Analysis using R (supplementary) (1) - Multiple regression analysis
ks91
PRO
0
13
Other Decks in Technology
See All in Technology
20241228 - 成為最強魔法使!AI 實時生成比賽的策略 @ 2024 SD AI 年會
dpys
0
230
20241125 - AI 繪圖實戰魔法工作坊 @ 實踐大學
dpys
1
340
英語が苦手でも学びが得られるWorkshopについて / About the workshop of re:Invent 2024
taquakisatwo
0
620
12 Days of OpenAIから読み解く、生成AI 2025年のトレンド
shunsukeono_am
0
770
TypeScript開発にモジュラーモノリスを持ち込む
sansantech
PRO
3
780
PHP ユーザのための OpenTelemetry 入門 / phpcon2024-opentelemetry
shin1x1
3
1.6k
Google Cloud で始める Cloud Run 〜AWSとの比較と実例デモで解説〜
risatube
PRO
0
120
20240513 - 框裡框外_文學院學生如何在AI世代安身立命 @ 淡江大學
dpys
0
460
20241218_今年はSLI/SLOの導入を頑張ってました!
zepprix
0
220
PHPerのための計算量入門/Complexity101 for PHPer
hanhan1978
6
1.3k
小学3年生夏休みの自由研究「夏休みに Copilot で遊んでみた」
taichinakamura
0
190
Oracle Cloudの生成AIサービスって実際どこまで使えるの? エンジニア目線で試してみた
minorun365
PRO
5
320
Featured
See All Featured
Six Lessons from altMBA
skipperchong
27
3.5k
Statistics for Hackers
jakevdp
796
220k
Code Review Best Practice
trishagee
65
17k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
Building an army of robots
kneath
302
44k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
29
2k
The Power of CSS Pseudo Elements
geoffreycrofte
73
5.4k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
171
50k
Keith and Marios Guide to Fast Websites
keithpitt
410
22k
Raft: Consensus for Rubyists
vanstee
137
6.7k
Optimizing for Happiness
mojombo
376
70k
4 Signs Your Business is Dying
shpigford
182
21k
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