SlideShare a Scribd company logo
1 of 9
マンガでわかるベイズ統計学
第3章 尤度関数2
微分法を用いて関数の傾きを求める
  32
pppL  の傾きを知りたい!
p p+h
L(p+h)
L(p)
台形を考えると、傾きはだいたい
   
h
pLhpL  と表現できる。
ここで、hを小さく小さく小さくしていくと
実際の関数の傾きになる。
   
h
pLhpL
h

0
lim
と記述される。
前回の最後のスライド
「尤度」と呼んだ
微分による具体的な傾き計算
          
      
   
 
2 3 2 3
0 0
2 2 3 2 2 3 2 3
0
2 2 2 3
0
2 2 2
0
2
lim lim
2 3 3
lim
2 3 3
lim
lim 2 3 3
2 3
h h
h
h
h
p h p h p pL p h L p
h h
p ph h p p h ph h p p
h
ph h p h ph h
h
p h p ph h
p p
 



     

       

   

    
 
  32
pppL  を微分する
地道に計算すると
これが「傾き」となる。
※この傾きがゼロになる点が最尤推定量だ
微分法の一般化(おまけ)
  n
L p p とすると
   
 
0
1
n
n
n k k
n k
k
n n
L p h p h
C p h
p np h h



  
  
  

に関する 高次の項
と計算されるので、微分すると
 
   
 
  
  
'
0
0
1
0
1
0
1
lim
lim
lim
lim
h
n n
h
n n n
h
n
h
n
L p h L p
L p
h
p h p
h
p np h h p
h
np h
np







 

 

  

 

に関する 高次項
を含む項
対数とは
http://oto-suu.seesaa.net/article/167913379.html
3
2 8
指数
23 log 8
対数(この数字が主役になる)
対数の底(底がeの場合、自然対数と呼ぶ)
対数の性質
導出は下記URLの「積の対数」にて
https://sci-pursuit.com/math/logarithm-formulae-and-calculation.html
 
2
2
2 2 2
3 log 8
log 2 2 2
log 2 log 2 log 2

  
   積を和に変換できる
情報量(おまけ)
2log p
定義
事象の発生確率
例
・宝くじの当選確率を1/16とすると、「当選した」という情報は4bitの情報を持つ
 
4
2 2
1
log log 2
16
4
4

  
  

対数尤度
   2 3 2
1L p p p p p    の傾きがゼロになるとき、尤度が最大となった。
式が単純であれば、直接微分してパラメータを求めればよい。
但し、一般的なモデルで直接微分することは難しい。
そこで、L(p)の対数をとる
  
  
 
 
2
2
ln
ln 1
ln ln 1
2ln ln 1
l L p
p p
p p
p p

 
  
  
対数尤度
※ln : 底がeの対数
対数尤度の傾きがゼロになる点を求めることで、
より簡単に最尤推定量を求められる
対数尤度の微分を用いた最尤推定
  
'
2ln ln 1
2 1
1
dl
l
dp
d
p p
dp
p p

  
 

対数尤度の微分値(傾き)が
ゼロになる点が最尤推定量に
なる!
    
'' 1 1
ln , ln 1
1
p p
p p
   

対数の微分公式
※参考
https://sci-pursuit.com/math/differential-logarithm.html

More Related Content

More from Satoshi Kawamoto (12)

マンガで分かるベイズ統計学勉強会(第1章+α)
マンガで分かるベイズ統計学勉強会(第1章+α)マンガで分かるベイズ統計学勉強会(第1章+α)
マンガで分かるベイズ統計学勉強会(第1章+α)
 
統計検定3級 5
統計検定3級 5統計検定3級 5
統計検定3級 5
 
統計検定3級 4
統計検定3級 4統計検定3級 4
統計検定3級 4
 
統計検定3級 3
統計検定3級 3統計検定3級 3
統計検定3級 3
 
統計検定3級 2
統計検定3級 2統計検定3級 2
統計検定3級 2
 
統計検定3級 1
統計検定3級 1統計検定3級 1
統計検定3級 1
 
Prml7 7.1
Prml7 7.1Prml7 7.1
Prml7 7.1
 
Prml 4.3.6
Prml 4.3.6Prml 4.3.6
Prml 4.3.6
 
Prml 4.3.5
Prml 4.3.5Prml 4.3.5
Prml 4.3.5
 
Prml 4.1.2
Prml 4.1.2Prml 4.1.2
Prml 4.1.2
 
Prml 4.1.1
Prml 4.1.1Prml 4.1.1
Prml 4.1.1
 
Prml 4
Prml 4Prml 4
Prml 4
 

Recently uploaded

【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)
【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)
【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)Hiroki Ichikura
 
論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...
論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...
論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...Toru Tamaki
 
TSAL operation mechanism and circuit diagram.pdf
TSAL operation mechanism and circuit diagram.pdfTSAL operation mechanism and circuit diagram.pdf
TSAL operation mechanism and circuit diagram.pdftaisei2219
 
SOPを理解する 2024/04/19 の勉強会で発表されたものです
SOPを理解する       2024/04/19 の勉強会で発表されたものですSOPを理解する       2024/04/19 の勉強会で発表されたものです
SOPを理解する 2024/04/19 の勉強会で発表されたものですiPride Co., Ltd.
 
TataPixel: 畳の異方性を利用した切り替え可能なディスプレイの提案
TataPixel: 畳の異方性を利用した切り替え可能なディスプレイの提案TataPixel: 畳の異方性を利用した切り替え可能なディスプレイの提案
TataPixel: 畳の異方性を利用した切り替え可能なディスプレイの提案sugiuralab
 
論文紹介:Semantic segmentation using Vision Transformers: A survey
論文紹介:Semantic segmentation using Vision Transformers: A survey論文紹介:Semantic segmentation using Vision Transformers: A survey
論文紹介:Semantic segmentation using Vision Transformers: A surveyToru Tamaki
 
論文紹介:Automated Classification of Model Errors on ImageNet
論文紹介:Automated Classification of Model Errors on ImageNet論文紹介:Automated Classification of Model Errors on ImageNet
論文紹介:Automated Classification of Model Errors on ImageNetToru Tamaki
 
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介Yuma Ohgami
 

Recently uploaded (8)

【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)
【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)
【早稲田AI研究会 講義資料】3DスキャンとTextTo3Dのツールを知ろう!(Vol.1)
 
論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...
論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...
論文紹介:Content-Aware Token Sharing for Efficient Semantic Segmentation With Vis...
 
TSAL operation mechanism and circuit diagram.pdf
TSAL operation mechanism and circuit diagram.pdfTSAL operation mechanism and circuit diagram.pdf
TSAL operation mechanism and circuit diagram.pdf
 
SOPを理解する 2024/04/19 の勉強会で発表されたものです
SOPを理解する       2024/04/19 の勉強会で発表されたものですSOPを理解する       2024/04/19 の勉強会で発表されたものです
SOPを理解する 2024/04/19 の勉強会で発表されたものです
 
TataPixel: 畳の異方性を利用した切り替え可能なディスプレイの提案
TataPixel: 畳の異方性を利用した切り替え可能なディスプレイの提案TataPixel: 畳の異方性を利用した切り替え可能なディスプレイの提案
TataPixel: 畳の異方性を利用した切り替え可能なディスプレイの提案
 
論文紹介:Semantic segmentation using Vision Transformers: A survey
論文紹介:Semantic segmentation using Vision Transformers: A survey論文紹介:Semantic segmentation using Vision Transformers: A survey
論文紹介:Semantic segmentation using Vision Transformers: A survey
 
論文紹介:Automated Classification of Model Errors on ImageNet
論文紹介:Automated Classification of Model Errors on ImageNet論文紹介:Automated Classification of Model Errors on ImageNet
論文紹介:Automated Classification of Model Errors on ImageNet
 
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介
Open Source UN-Conference 2024 Kawagoe - 独自OS「DaisyOS GB」の紹介
 

マンガで分かるベイズ統計学勉強会(第3章その2)