MCMC (Markov chain Monte Carlo) is a family of methods that are applied in computational physics and chemistry and also widely used in bayesian machine learning. It is used to simulate physical systems with Gibbs canonical distribution: $$ p(\vx) \propto \exp\left( - \frac{U(\vx)}{T} \right) $$ Probability `$ p(\vx) $` of a system to be in the state `$ \vx $` depends on the energy of the state `$U
熊谷さんが負の二項分布のパラメータ推定をWinBUGSでやっておられたので、JAGSとStanでもやってみました。 Rのコード ## ## Negative Binomial ## ## JAGS library(rjags) set.seed(1234) n <- 100 mu <- exp(2) r <- 1.5 Y <- rnbinom(n, size = r, mu = mu) params <- c("mu", "r") inits <- lapply(1:3, function(i) list(p = runif(1, 0, 1), r = rpois(1, 20) + 1)) model <- jags.model("negbin.bug", data = list(N = n, Y = Y), inits = inits, n.chains = 3, n.adapt = 5
応用範囲が広く幅広い視点からの説明になりがちなベイズ最適化について、本記事では機械学習のハイパーパラメータ探索に利用することに限定して解説します。 1. はじめに 最近、ベイズ最適化という手法が注目を集めています。 ベイズ最適化 (Bayesian Optimization) とは、形状がわからない関数 (ブラックボックス関数) の最大値 (または最小値) を求めるための手法です。 ベイズ最適化についての入門記事は Web 上にすでにいくつかありますが、ベイズ最適化は応用範囲が広く、入門記事は様々な応用に向けた幅広い視点からの説明になりがちです。 本記事では、機械学習ユーザに向けて、ベイズ最適化を機械学習のハイパーパラメータ探索に利用することに限定して説明します。 これにより、機械学習に対して、ベイズ最適化がどのように利用できるのかを分かりやすく解説したいと思います。 2. ハイパーパラメ
ハミルトニアンモンテカルロ法(HMC)の動作原理をアニメーションを用いて理解してみようという記事です。 先日の記事、「【統計学】マルコフ連鎖モンテカルロ法(MCMC)によるサンプリングをアニメーションで解説してみる。」の続編にあたります。 豊田先生の書籍「基礎からのベイズ統計学」の例題を使わせていただき、サンプリング対象の分布は今回ガンマ分布とします。本記事ではアニメーションに使った部分の理論的な解説しかしませんので、HMCの詳細な解説はこちらの書籍をご参照いただければと思います。 はじめに 推定する対象は$\theta$を変数としたガンマ分布です。ベイズ推定で推定したいパラメーターを$\theta$で表すので、$\theta$の分布として表されます。1 ガンマ分布はこちらです。 $$ f(\theta|\alpha, \lambda) = {\lambda^{\alpha} \over
あらかじめ書いておきますが、ここに書いてあることは間違ってる可能性が高いので気をつけてください。でも以前のメモも素晴らしく貴重なコメントの数々をいただきました(大感謝)ので、きっとコメント込みで読んでいただければ何らかのお役に立てるような気がしてきました。 DICの直感的な理解を目指したメモ(さらにアヤしい) さて、前回のメモではAICにおいては「パラメータ推定に関する何らかの不確実性」が「パラメータの数」として表現されているのではないか、と妄想しました*1。 おそらく、このような考え方はそのままではベイズの世界には持ち込めません。なぜならベイズでは「パラメータ自体が事前分布という"情報"を連れている*2」という事情があるからです。 このような場合には、「パラメータ推定に関する不確実性」というのはパラメータが持つ事前分布に依存することになりそうです。極端なことを言えば、あるパラメータの事前
専修大学 岡田謙介 日本行動計量学会 第17回春の合宿セミナー 2015年03月08日 行動計量学のための ベイズ推定における モデル選択・評価 2 https://twitter.com/amstatnews/status/547403146365272064 前世紀的な統計分析 統計分析が行えるモデルの数が限られてり、そう した実行可能なモデルにデータをあわせる 心理学分野では分散分析の濫用 連続変数を測定しているにもかかわらず、モデ ルに当てはめるために上位群・下位群に分け て分析する、などの悪しき慣習 時代背景 古来は数表を利用する必要があった 比較的近年でも、統計ソフトウェアはモデルごと に機能分化しており、汎用的な推定ができな かった 3 現代的な統計分析 データのもっている特性をよく表現し、予測できる 統計モデルを構築し、それを用いたパラメータ推 定・予
【宣伝】2016/09/14 このページに来た方へ。あなたが求めている本はこれです。 StanとRでベイズ統計モデリング (Wonderful R) 作者: 松浦健太郎,石田基広出版社/メーカー: 共立出版発売日: 2016/10/25メディア: 単行本この商品を含むブログ (10件) を見るまずこれを予約してから下記を読むといいです。 【宣伝終】 最近、ベイズ統計の入門書がたくさん出版されているので、ここで一旦まとめてみようと思います。 1. 基礎からのベイズ統計学: ハミルトニアンモンテカルロ法による実践的入門 (2015/6/25) 基礎からのベイズ統計学: ハミルトニアンモンテカルロ法による実践的入門 作者: 豊田秀樹出版社/メーカー: 朝倉書店発売日: 2015/06/25メディア: 単行本この商品を含むブログ (6件) を見る データ分析業界ではかなり有名な豊田秀樹先生の本です
Bayesian Analysis for Epidemiologists III: Regression Modeling Acknowledgements Much of this material comes from a workshop run by Drs. David Spiegelhalter and Nicky Best in Cambridge, UK, in 2005. Other major contributions come (again) from Lyle Gurrin and Shane Jensen. Jim Albert David Spiegelhalter Nicky Best Andrew Gelman Bendix Carstensen Lyle Guerrin Shane Jensen and Statistical Horizons Sec
JAGS What is JAGS? JAGS is Just Another Gibbs Sampler. It is a program for analysis of Bayesian hierarchical models using Markov Chain Monte Carlo (MCMC) simulation not wholly unlike BUGS. JAGS was written with three aims in mind: To have a cross-platform engine for the BUGS language To be extensible, allowing users to write their own functions, distributions and samplers. To be a platform for
岩波データサイエンス サポートページ 各巻に対応する内容は,上のバーの3本線「三」をクリックして左に表示されるメニューからご覧ください (トップページの内容が空白の場合も,メニューで下位の階層をクリックして頂くと内容が表示される場合があります) 新グーグル・サイトに移行しました.自動変換のため,見難くなっている部分,表示されない部分がありますが,ご容赦ください シリーズ「岩波データサイエンス」では、統計科学や機械学習など、データを扱うさまざまな分野について、多様な視点からの情報を提供することをめざします。まったくの初歩からやや高度な話までのいろいろな手法の解説、実務に役立つソフトの使い方、さらには各領域のサイエンスや応用に踏み込んだ内容まで、多彩な記事を掲載します。 装丁には蛯名優子さんの作品を使わせて頂いています。蛯名さんのホームページはこちらです。 【公式ツイッターアカウント】ツイッタ
(※Stan v2.4.0以降でインストール方法に若干変更があります!詳しくはこの記事の中ほどをご覧ください) さて、年初の抱負でも語ったように今年はStanを頑張って会得していこうと思います。理由は簡単で、ありったけの要素を詰め込んでMCMCサンプラーでガンガン推定していくような階層ベイズモデリングに自分の興味としても惹かれる上に、実務でも必要になりそうな見通し*1だからです。 Stan: Project Home Page 既に以前の記事でも簡単に触れてますが、StanはC++ベースのコンパイラで高速化させたMCMCサンプラーです。文法も簡単でなおかつ高速なので、BUGSでは時間がかかり過ぎて辛かった計算でも比較的サクサク回せます。 このシリーズを通して参考にするのは、@berobero11さんのブログです。 Small Data Scientist Memorandum 本当にもう、
This site is dedicated to the book “Bayesian Cognitive Modeling: A Practical Course”, published by Cambridge University Press. Here are links for the: Google Books, Amazon US, Amazon UK, and Cambridge University Press sites. This book forms the basis for a week-long course that we teach in Amsterdam, during the summer. We’d love to see you there. Follow this link for the 2024 course, which will be
東京大学医学部卒(生物統計学専攻)。東京大学大学院医学系研究科医療コミュニケーション学分野助教、大学病院医療情報ネットワーク研究センター副センター長、ダナファーバー/ハーバードがん研究センター客員研究員を経て、現在はデータを活用する様々なプロジェクトにおいて調査、分析、システム開発および人材育成に従事する。著書に『統計学が最強の学問である』(ダイヤモンド社)、『1億人のための統計解析』(日経BP社)などがある。 『統計学が最強の学問である[実践編]』発刊記念対談 35万部を突破したベストセラー『統計学が最強の学問である』の続編、『統計学が最強の学問である[実践編]』の出版を記念し、著者・西内啓氏をホストに統計学をめぐるシリーズ対談の連載がスタートします。 ゲストは前統計学会会長、気鋭の経済学者、統計学者など。普段は知ることのできない統計学者の斬新な視点と意見をお楽しみください。 バックナン
Not your computer? Use a private browsing window to sign in. Learn more about using Guest mode
For more information, please click links in menu at left, or in the pop-up menu on small screens (see menu icon at top left). There may be formatting infelicities on some pages. In August 2020, the site host (Google Sites) required migration to new formatting. The automatic re-formatting mangled some pages, but I think they are all at least functional. I appreciate your forbearance and hope you ca
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く