SlideShare a Scribd company logo
1 of 7
確率の乗法定理 P(A∩B) = P(A)P(B/A)・・①  A B A∩B A⇒Bを入れ替えると P(A∩B) = P(B)P(A/B)  P(A∩B) =  P(A/B) P(B)・・②  ①と②の左辺P(A∩B)共通なので P(A)P(B/A) =  P(A/B) P(B)・・③  ③について、P(B)≠0を仮定し、P(A/B)について解くと P(B/A) P(A)  P(A/B) =  P(B)
ベイズ統計の基本(覚書) その1 「Excelでスッキリわかるベイズ統計入門」(日本実業出版社) からのMEMO
ベイズの定理 H(仮定:原因) D(結果:データ) P(D/H):尤度=原因Hのもとで          現象の起こる尤もらしい確率 P(H/D):結果から原因をさぐる           原因の確立=事後確率 H D D H H(仮定:原因) D(結果:現象;データ) D(結果:現象:データ) H(仮定:原因) P(H/D) :事後確率 P(H):  事前確率 P(D):  結果・現象=データ  の起こる確率 <尤度> <事前確率> P(D/H) P(H)  <事後確率> P(H/D) =  P(D)
ベイズの展開公式 H1、H2、H3はそれぞれ独立 H1 H2 H3 原因H1 原因H2 原因H3 D∩H1 D∩H2 D∩H3 データD D HをH1に置き換えると P(D/H) P(H)  P(D/H1) P(H1)  P(H/D) =  P(H1/D) =  ・・① P(D) P(D) H1、H2、H3はそれぞれ独立とすると P(D)= P(D∩H1) +  P(D∩H2) +  P(D∩H3)   P(D)= P(D/H1)P(H1) + P(D/H2)P(H2) + P(D/H3)P(H3)   ・・② ①に②を代入 P(D/H1) P(H1)  P(H1/D) =  P(D/H1)P(H1) + P(D/H2)P(H2) + P(D/H3)P(H3)   ベイズの展開公式 P(D/Hi) P(Hi)  P(Hi/D) =  P(D/H1)P(H1) + P(D/H2)P(H2) +・・+ P(D/Hi)P(Hi)  
ベイズ統計の基本公式 母数が連続変数の場合のベイズの定理: 母数がθである確率公式として捉えなおす。 <尤度> <事前確率> P(D/θ) P(θ)  P(D/H) P(H)  <事後確率> P(θ/D) =  P(H/D) =  P(D) P(D) Θが連続的な値をとるとき、P(D)、P(D/θ)、P(θ/D)の解釈を「確率」⇒「確率密度」に変える。 (事前確率) P(θ)   ⇒ (事前分布) π(θ) (尤度) P(D/θ)     ⇒ (尤度)    f(D/θ) (事後確率) P(θ/D)  ⇒ (事後分布) π(θ/D) <尤度> <事前分布> f(D/θ) π(θ)  <事後分布> π(θ/D) =  P(D) ・・データDを得る確率   ⇒データが与えられた後は一定な数値になる 事後分布は、尤度と事前分布の積に比例する。 事後分布π(θ/D) ∝ 尤度f(D/θ)×事前分布π(θ) 
ベイズ統計の基本公式の活用例 <具体例:薬の効果θの事後分布>
ベイズ推定 ■統計的推定: 確率的な乗法から未知な値を決定すること ■ベイズ推定: 事後確率や事後分布を用いて、不明の値を最適に決定            ⇒分布の代表値の推定を行う。「期待損失最小化」原理を活用 ■期待損失最小化:  平方損失 θ α 2 絶対損失 θ α 一様損失 θ α α- α+ ●損失関数として平方損失を選んだ場合: 平均値を母数の推定値として利用。 ベイズ推定では、平均値算出に事後分布を使う ●損失関数として一様損失を選んだ場合: 最頻値を推定値として利用。 ⇒最大事後確率推定法(Maximum a posteriori estimation method)   =MAP推定法(推定値をMAP推定値) 事後分布 事後分布 平均値 MAP推定値

More Related Content

Recently uploaded

ゲーム理論 BASIC 演習106 -価格の交渉ゲーム-#ゲーム理論 #gametheory #数学
ゲーム理論 BASIC 演習106 -価格の交渉ゲーム-#ゲーム理論 #gametheory #数学ゲーム理論 BASIC 演習106 -価格の交渉ゲーム-#ゲーム理論 #gametheory #数学
ゲーム理論 BASIC 演習106 -価格の交渉ゲーム-#ゲーム理論 #gametheory #数学ssusere0a682
 
東京工業大学 環境・社会理工学院 建築学系 大学院入学入試・進学説明会2024_v2
東京工業大学 環境・社会理工学院 建築学系 大学院入学入試・進学説明会2024_v2東京工業大学 環境・社会理工学院 建築学系 大学院入学入試・進学説明会2024_v2
東京工業大学 環境・社会理工学院 建築学系 大学院入学入試・進学説明会2024_v2Tokyo Institute of Technology
 
ゲーム理論 BASIC 演習105 -n人囚人のジレンマモデル- #ゲーム理論 #gametheory #数学
ゲーム理論 BASIC 演習105 -n人囚人のジレンマモデル- #ゲーム理論 #gametheory #数学ゲーム理論 BASIC 演習105 -n人囚人のジレンマモデル- #ゲーム理論 #gametheory #数学
ゲーム理論 BASIC 演習105 -n人囚人のジレンマモデル- #ゲーム理論 #gametheory #数学ssusere0a682
 
The_Five_Books_Overview_Presentation_2024
The_Five_Books_Overview_Presentation_2024The_Five_Books_Overview_Presentation_2024
The_Five_Books_Overview_Presentation_2024koheioishi1
 
生成AIの回答内容の修正を課題としたレポートについて:お茶の水女子大学「授業・研究における生成系AIの活用事例」での講演資料
生成AIの回答内容の修正を課題としたレポートについて:お茶の水女子大学「授業・研究における生成系AIの活用事例」での講演資料生成AIの回答内容の修正を課題としたレポートについて:お茶の水女子大学「授業・研究における生成系AIの活用事例」での講演資料
生成AIの回答内容の修正を課題としたレポートについて:お茶の水女子大学「授業・研究における生成系AIの活用事例」での講演資料Takayuki Itoh
 
TokyoTechGraduateExaminationPresentation
TokyoTechGraduateExaminationPresentationTokyoTechGraduateExaminationPresentation
TokyoTechGraduateExaminationPresentationYukiTerazawa
 
UniProject Workshop Make a Discord Bot with JavaScript
UniProject Workshop Make a Discord Bot with JavaScriptUniProject Workshop Make a Discord Bot with JavaScript
UniProject Workshop Make a Discord Bot with JavaScriptyuitoakatsukijp
 

Recently uploaded (7)

ゲーム理論 BASIC 演習106 -価格の交渉ゲーム-#ゲーム理論 #gametheory #数学
ゲーム理論 BASIC 演習106 -価格の交渉ゲーム-#ゲーム理論 #gametheory #数学ゲーム理論 BASIC 演習106 -価格の交渉ゲーム-#ゲーム理論 #gametheory #数学
ゲーム理論 BASIC 演習106 -価格の交渉ゲーム-#ゲーム理論 #gametheory #数学
 
東京工業大学 環境・社会理工学院 建築学系 大学院入学入試・進学説明会2024_v2
東京工業大学 環境・社会理工学院 建築学系 大学院入学入試・進学説明会2024_v2東京工業大学 環境・社会理工学院 建築学系 大学院入学入試・進学説明会2024_v2
東京工業大学 環境・社会理工学院 建築学系 大学院入学入試・進学説明会2024_v2
 
ゲーム理論 BASIC 演習105 -n人囚人のジレンマモデル- #ゲーム理論 #gametheory #数学
ゲーム理論 BASIC 演習105 -n人囚人のジレンマモデル- #ゲーム理論 #gametheory #数学ゲーム理論 BASIC 演習105 -n人囚人のジレンマモデル- #ゲーム理論 #gametheory #数学
ゲーム理論 BASIC 演習105 -n人囚人のジレンマモデル- #ゲーム理論 #gametheory #数学
 
The_Five_Books_Overview_Presentation_2024
The_Five_Books_Overview_Presentation_2024The_Five_Books_Overview_Presentation_2024
The_Five_Books_Overview_Presentation_2024
 
生成AIの回答内容の修正を課題としたレポートについて:お茶の水女子大学「授業・研究における生成系AIの活用事例」での講演資料
生成AIの回答内容の修正を課題としたレポートについて:お茶の水女子大学「授業・研究における生成系AIの活用事例」での講演資料生成AIの回答内容の修正を課題としたレポートについて:お茶の水女子大学「授業・研究における生成系AIの活用事例」での講演資料
生成AIの回答内容の修正を課題としたレポートについて:お茶の水女子大学「授業・研究における生成系AIの活用事例」での講演資料
 
TokyoTechGraduateExaminationPresentation
TokyoTechGraduateExaminationPresentationTokyoTechGraduateExaminationPresentation
TokyoTechGraduateExaminationPresentation
 
UniProject Workshop Make a Discord Bot with JavaScript
UniProject Workshop Make a Discord Bot with JavaScriptUniProject Workshop Make a Discord Bot with JavaScript
UniProject Workshop Make a Discord Bot with JavaScript
 

Featured

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by HubspotMarius Sescu
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTExpeed Software
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsPixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 

Featured (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

ベイズ基本0425

  • 1. 確率の乗法定理 P(A∩B) = P(A)P(B/A)・・①  A B A∩B A⇒Bを入れ替えると P(A∩B) = P(B)P(A/B)  P(A∩B) =  P(A/B) P(B)・・②  ①と②の左辺P(A∩B)共通なので P(A)P(B/A) =  P(A/B) P(B)・・③  ③について、P(B)≠0を仮定し、P(A/B)について解くと P(B/A) P(A)  P(A/B) =  P(B)
  • 3. ベイズの定理 H(仮定:原因) D(結果:データ) P(D/H):尤度=原因Hのもとで          現象の起こる尤もらしい確率 P(H/D):結果から原因をさぐる           原因の確立=事後確率 H D D H H(仮定:原因) D(結果:現象;データ) D(結果:現象:データ) H(仮定:原因) P(H/D) :事後確率 P(H):  事前確率 P(D):  結果・現象=データ  の起こる確率 <尤度> <事前確率> P(D/H) P(H)  <事後確率> P(H/D) =  P(D)
  • 4. ベイズの展開公式 H1、H2、H3はそれぞれ独立 H1 H2 H3 原因H1 原因H2 原因H3 D∩H1 D∩H2 D∩H3 データD D HをH1に置き換えると P(D/H) P(H)  P(D/H1) P(H1)  P(H/D) =  P(H1/D) =  ・・① P(D) P(D) H1、H2、H3はそれぞれ独立とすると P(D)= P(D∩H1) +  P(D∩H2) +  P(D∩H3)   P(D)= P(D/H1)P(H1) + P(D/H2)P(H2) + P(D/H3)P(H3)   ・・② ①に②を代入 P(D/H1) P(H1)  P(H1/D) =  P(D/H1)P(H1) + P(D/H2)P(H2) + P(D/H3)P(H3)   ベイズの展開公式 P(D/Hi) P(Hi)  P(Hi/D) =  P(D/H1)P(H1) + P(D/H2)P(H2) +・・+ P(D/Hi)P(Hi)  
  • 5. ベイズ統計の基本公式 母数が連続変数の場合のベイズの定理: 母数がθである確率公式として捉えなおす。 <尤度> <事前確率> P(D/θ) P(θ)  P(D/H) P(H)  <事後確率> P(θ/D) =  P(H/D) =  P(D) P(D) Θが連続的な値をとるとき、P(D)、P(D/θ)、P(θ/D)の解釈を「確率」⇒「確率密度」に変える。 (事前確率) P(θ)   ⇒ (事前分布) π(θ) (尤度) P(D/θ)     ⇒ (尤度)    f(D/θ) (事後確率) P(θ/D)  ⇒ (事後分布) π(θ/D) <尤度> <事前分布> f(D/θ) π(θ)  <事後分布> π(θ/D) =  P(D) ・・データDを得る確率   ⇒データが与えられた後は一定な数値になる 事後分布は、尤度と事前分布の積に比例する。 事後分布π(θ/D) ∝ 尤度f(D/θ)×事前分布π(θ) 
  • 7. ベイズ推定 ■統計的推定: 確率的な乗法から未知な値を決定すること ■ベイズ推定: 事後確率や事後分布を用いて、不明の値を最適に決定            ⇒分布の代表値の推定を行う。「期待損失最小化」原理を活用 ■期待損失最小化:  平方損失 θ α 2 絶対損失 θ α 一様損失 θ α α- α+ ●損失関数として平方損失を選んだ場合: 平均値を母数の推定値として利用。 ベイズ推定では、平均値算出に事後分布を使う ●損失関数として一様損失を選んだ場合: 最頻値を推定値として利用。 ⇒最大事後確率推定法(Maximum a posteriori estimation method) =MAP推定法(推定値をMAP推定値) 事後分布 事後分布 平均値 MAP推定値