{"id":659,"date":"2021-08-09T15:53:06","date_gmt":"2021-08-09T15:53:06","guid":{"rendered":"https:\/\/www.allendowney.com\/blog\/?p=659"},"modified":"2021-08-09T15:53:06","modified_gmt":"2021-08-09T15:53:06","slug":"bayesian-dice","status":"publish","type":"post","link":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/","title":{"rendered":"Bayesian Dice"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">This article is available in a Jupyter notebook: <a href=\"https:\/\/colab.research.google.com\/github\/AllenDowney\/ThinkBayes2\/blob\/master\/examples\/bayes_dice.ipynb\">click here to run it on Colab<\/a>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">I\u2019ve been enjoying Aubrey Clayton\u2019s new book <a href=\"https:\/\/aubreyclayton.com\/bernoulli\"><em>Bernoulli\u2019s Fallacy<\/em><\/a>. The first chapter, which is about the historical development of competing definitions of probability, is worth the price of admission alone.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">One of the examples in Chapter 1 is a simplified version of a problem posed by Thomas Bayes. The original version, <a href=\"https:\/\/allendowney.blogspot.com\/2015\/06\/bayesian-billiards.html\">which I wrote about here<\/a>, involves a billiards (pool) table; Clayton\u2019s version uses dice:<\/p>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\"><p>Your friend rolls a six-sided die and secretly records the outcome; this number becomes the target <em>T<\/em>. You then put on a blindfold and roll the same six-sided die over and over. You\u2019re unable to see how it lands, so each time your friend [\u2026] tells you <em>only<\/em> whether the number you just rolled was greater than, equal to, or less than <em>T<\/em>.<\/p><p>Suppose in one round of the game we had this sequence of outcomes, with G representing a greater roll, L a lesser roll, and E an equal roll:<\/p><p>G, G, L, E, L, L, L, E, G, L<\/p><cite>Clayton, <em>Bernoulli&#8217;s Fallacy<\/em>, pg 36.<\/cite><\/blockquote>\n\n\n\n<p class=\"wp-block-paragraph\">Based on this data, what is the posterior distribution of <em>T<\/em>?<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Computing likelihoods<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">There are two parts of my solution; computing the likelihood of the data under each hypothesis and then using those likelihoods to compute the posterior distribution of <em>T<\/em>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">To compute the likelihoods, I\u2019ll demonstrate one of my favorite idioms, using a meshgrid to apply an operation, like <code>&gt;<\/code>, to all pairs of values from two sequences.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In this case, the sequences are<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><code>hypos<\/code>: The hypothetical values of <em>T<\/em>, and<\/li><li><code>outcomes<\/code>: possible outcomes each time we roll the dice<\/li><\/ul>\n\n\n\n<pre id=\"codecell0\" class=\"wp-block-preformatted\">hypos = [1,2,3,4,5,6]\noutcomes = [1,2,3,4,5,6]<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If we compute a meshgrid of <code>outcomes<\/code> and <code>hypos<\/code>, the result is two arrays.<\/p>\n\n\n\n<pre id=\"codecell1\" class=\"wp-block-preformatted\">import numpy as np\n\nO, H = np.meshgrid(outcomes, hypos)<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The first contains the possible outcomes repeated down the columns.<\/p>\n\n\n\n<pre id=\"codecell2\" class=\"wp-block-preformatted\">O<\/pre>\n\n\n\n<pre id=\"codecell3\" class=\"wp-block-preformatted\">array([[1, 2, 3, 4, 5, 6],\n       [1, 2, 3, 4, 5, 6],\n       [1, 2, 3, 4, 5, 6],\n       [1, 2, 3, 4, 5, 6],\n       [1, 2, 3, 4, 5, 6],\n       [1, 2, 3, 4, 5, 6]])<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The second contains the hypotheses repeated across the rows.<\/p>\n\n\n\n<pre id=\"codecell4\" class=\"wp-block-preformatted\">H<\/pre>\n\n\n\n<pre id=\"codecell5\" class=\"wp-block-preformatted\">array([[1, 1, 1, 1, 1, 1],\n       [2, 2, 2, 2, 2, 2],\n       [3, 3, 3, 3, 3, 3],\n       [4, 4, 4, 4, 4, 4],\n       [5, 5, 5, 5, 5, 5],\n       [6, 6, 6, 6, 6, 6]])<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If we apply an operator like <code>&gt;<\/code>, the result is a Boolean array.<\/p>\n\n\n\n<pre id=\"codecell6\" class=\"wp-block-preformatted\">O > H<\/pre>\n\n\n\n<pre id=\"codecell7\" class=\"wp-block-preformatted\">array([[False,  True,  True,  True,  True,  True],\n       [False, False,  True,  True,  True,  True],\n       [False, False, False,  True,  True,  True],\n       [False, False, False, False,  True,  True],\n       [False, False, False, False, False,  True],\n       [False, False, False, False, False, False]])<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Now we can use <code>mean<\/code> with <code>axis=1<\/code> to compute the fraction of <code>True<\/code> values in each row.<\/p>\n\n\n\n<pre id=\"codecell8\" class=\"wp-block-preformatted\">(O > H).mean(axis=1)<\/pre>\n\n\n\n<pre id=\"codecell9\" class=\"wp-block-preformatted\">array([0.83333333, 0.66666667, 0.5       , 0.33333333, 0.16666667,\n       0.        ])<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The result is the probability that the outcome is greater than <em>T<\/em>, for each hypothetical value of <em>T<\/em>. I\u2019ll name this array <code>gt<\/code>:<\/p>\n\n\n\n<pre id=\"codecell10\" class=\"wp-block-preformatted\">gt = (O > H).mean(axis=1)<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The first element of the array is 5\/6, which indicates that if <em>T<\/em> is 1, the probability of exceeding it is 5\/6. The second element is 2\/3, which indicates that if <em>T<\/em> is 2, the probability of exceeding it is 2\/3. And do on.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Now we can compute the corresponding arrays for less than and equal.<\/p>\n\n\n\n<pre id=\"codecell12\" class=\"wp-block-preformatted\">lt = (O &lt; H).mean(axis=1)<\/pre>\n\n\n\n<pre id=\"codecell13\" class=\"wp-block-preformatted\">array([0.        , 0.16666667, 0.33333333, 0.5       , 0.66666667,\n       0.83333333])<\/pre>\n\n\n\n<pre id=\"codecell14\" class=\"wp-block-preformatted\">eq = (O == H).mean(axis=1)<\/pre>\n\n\n\n<pre id=\"codecell15\" class=\"wp-block-preformatted\">array([0.16666667, 0.16666667, 0.16666667, 0.16666667, 0.16666667,\n       0.16666667])<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">In the next section, we\u2019ll use these arrays to do a Bayesian update.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">The Update<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">In this example, computing the likelihoods was the hard part. The Bayesian update is easy. Since <em>T<\/em> was chosen by rolling a fair die, the prior distribution for <em>T<\/em> is uniform. I\u2019ll use a Pandas <code>Series<\/code> to represent it.<\/p>\n\n\n\n<pre id=\"codecell16\" class=\"wp-block-preformatted\">import pandas as pd\n\npmf = pd.Series(1\/6, hypos)\npmf<\/pre>\n\n\n\n<pre id=\"codecell17\" class=\"wp-block-preformatted\">1    0.166667\n2    0.166667\n3    0.166667\n4    0.166667\n5    0.166667\n6    0.166667<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Now here\u2019s the sequence of data, encoded using the likelihoods we computed in the previous section.<\/p>\n\n\n\n<pre id=\"codecell18\" class=\"wp-block-preformatted\">data = [gt, gt, lt, eq, lt, lt, lt, eq, gt, lt]<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The following loop updates the prior distribution by multiplying by each of the likelihoods.<\/p>\n\n\n\n<pre id=\"codecell19\" class=\"wp-block-preformatted\">for datum in data:\n    pmf *= datum<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Finally, we normalize the posterior.<\/p>\n\n\n\n<pre id=\"codecell20\" class=\"wp-block-preformatted\">pmf \/= pmf.sum()<\/pre>\n\n\n\n<pre id=\"codecell21\" class=\"wp-block-preformatted\">1    0.000000\n2    0.016427\n3    0.221766\n4    0.498973\n5    0.262834\n6    0.000000<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Here\u2019s what it looks like. <\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/allendowney.github.io\/ThinkBayes2\/_images\/bayes_dice_30_0.png\" alt=\"_images\/bayes_dice_30_0.png\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">As an aside, you might have noticed that the values in <code>eq<\/code> are all the same. So when the value we roll is equal to <em>T<\/em>, we don\u2019t get any new information about <em>T<\/em>. We could leave the instances of <code>eq<\/code> out of the data, and we would get the same answer.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This article is available in a Jupyter notebook: click here to run it on Colab. I\u2019ve been enjoying Aubrey Clayton\u2019s new book Bernoulli\u2019s Fallacy. The first chapter, which is about the historical development of competing definitions of probability, is worth the price of admission alone. One of the examples in Chapter 1 is a simplified version of a problem posed by Thomas Bayes. The original version, which I wrote about here, involves a billiards (pool) table; Clayton\u2019s version uses dice:&#8230;<\/p>\n<p class=\"read-more\"><a class=\"btn btn-default\" href=\"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/\"> Read More<span class=\"screen-reader-text\">  Read More<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[1],"tags":[63],"class_list":["post-659","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-bayess-theorem"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Bayesian Dice - Probably Overthinking It<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Bayesian Dice - Probably Overthinking It\" \/>\n<meta property=\"og:description\" content=\"This article is available in a Jupyter notebook: click here to run it on Colab. I\u2019ve been enjoying Aubrey Clayton\u2019s new book Bernoulli\u2019s Fallacy. The first chapter, which is about the historical development of competing definitions of probability, is worth the price of admission alone. One of the examples in Chapter 1 is a simplified version of a problem posed by Thomas Bayes. The original version, which I wrote about here, involves a billiards (pool) table; Clayton\u2019s version uses dice:... Read More Read More\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/\" \/>\n<meta property=\"og:site_name\" content=\"Probably Overthinking It\" \/>\n<meta property=\"article:published_time\" content=\"2021-08-09T15:53:06+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/allendowney.github.io\/ThinkBayes2\/_images\/bayes_dice_30_0.png\" \/>\n<meta name=\"author\" content=\"AllenDowney\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@AllenDowney\" \/>\n<meta name=\"twitter:site\" content=\"@AllenDowney\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"AllenDowney\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/\"},\"author\":{\"name\":\"AllenDowney\",\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/#\\\/schema\\\/person\\\/4e5bfb2e9af6c3446cb0031a7bf83207\"},\"headline\":\"Bayesian Dice\",\"datePublished\":\"2021-08-09T15:53:06+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/\"},\"wordCount\":558,\"publisher\":{\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/allendowney.github.io\\\/ThinkBayes2\\\/_images\\\/bayes_dice_30_0.png\",\"keywords\":[\"Bayes&#039;s Theorem\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/\",\"url\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/\",\"name\":\"Bayesian Dice - Probably Overthinking It\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/allendowney.github.io\\\/ThinkBayes2\\\/_images\\\/bayes_dice_30_0.png\",\"datePublished\":\"2021-08-09T15:53:06+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/#primaryimage\",\"url\":\"https:\\\/\\\/allendowney.github.io\\\/ThinkBayes2\\\/_images\\\/bayes_dice_30_0.png\",\"contentUrl\":\"https:\\\/\\\/allendowney.github.io\\\/ThinkBayes2\\\/_images\\\/bayes_dice_30_0.png\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/2021\\\/08\\\/09\\\/bayesian-dice\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Bayesian Dice\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/\",\"name\":\"Probably Overthinking It\",\"description\":\"Data science, Bayesian Statistics, and other ideas\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/#organization\",\"name\":\"Probably Overthinking It\",\"url\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/wp-content\\\/uploads\\\/2025\\\/03\\\/probably_logo.png\",\"contentUrl\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/wp-content\\\/uploads\\\/2025\\\/03\\\/probably_logo.png\",\"width\":714,\"height\":784,\"caption\":\"Probably Overthinking It\"},\"image\":{\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/x.com\\\/AllenDowney\",\"https:\\\/\\\/www.linkedin.com\\\/in\\\/allendowney\\\/\",\"https:\\\/\\\/bsky.app\\\/profile\\\/allendowney.bsky.social\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/#\\\/schema\\\/person\\\/4e5bfb2e9af6c3446cb0031a7bf83207\",\"name\":\"AllenDowney\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/fb01b3a7f7190bea1bbf7f0852e686c2f8c03b099222df2ce4bc7926f15bcb43?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/fb01b3a7f7190bea1bbf7f0852e686c2f8c03b099222df2ce4bc7926f15bcb43?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/fb01b3a7f7190bea1bbf7f0852e686c2f8c03b099222df2ce4bc7926f15bcb43?s=96&d=mm&r=g\",\"caption\":\"AllenDowney\"},\"url\":\"https:\\\/\\\/www.allendowney.com\\\/blog\\\/author\\\/allendowney_6dbrc4\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Bayesian Dice - Probably Overthinking It","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/","og_locale":"en_US","og_type":"article","og_title":"Bayesian Dice - Probably Overthinking It","og_description":"This article is available in a Jupyter notebook: click here to run it on Colab. I\u2019ve been enjoying Aubrey Clayton\u2019s new book Bernoulli\u2019s Fallacy. The first chapter, which is about the historical development of competing definitions of probability, is worth the price of admission alone. One of the examples in Chapter 1 is a simplified version of a problem posed by Thomas Bayes. The original version, which I wrote about here, involves a billiards (pool) table; Clayton\u2019s version uses dice:... Read More Read More","og_url":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/","og_site_name":"Probably Overthinking It","article_published_time":"2021-08-09T15:53:06+00:00","og_image":[{"url":"https:\/\/allendowney.github.io\/ThinkBayes2\/_images\/bayes_dice_30_0.png","type":"","width":"","height":""}],"author":"AllenDowney","twitter_card":"summary_large_image","twitter_creator":"@AllenDowney","twitter_site":"@AllenDowney","twitter_misc":{"Written by":"AllenDowney","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/#article","isPartOf":{"@id":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/"},"author":{"name":"AllenDowney","@id":"https:\/\/www.allendowney.com\/blog\/#\/schema\/person\/4e5bfb2e9af6c3446cb0031a7bf83207"},"headline":"Bayesian Dice","datePublished":"2021-08-09T15:53:06+00:00","mainEntityOfPage":{"@id":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/"},"wordCount":558,"publisher":{"@id":"https:\/\/www.allendowney.com\/blog\/#organization"},"image":{"@id":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/#primaryimage"},"thumbnailUrl":"https:\/\/allendowney.github.io\/ThinkBayes2\/_images\/bayes_dice_30_0.png","keywords":["Bayes&#039;s Theorem"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/","url":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/","name":"Bayesian Dice - Probably Overthinking It","isPartOf":{"@id":"https:\/\/www.allendowney.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/#primaryimage"},"image":{"@id":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/#primaryimage"},"thumbnailUrl":"https:\/\/allendowney.github.io\/ThinkBayes2\/_images\/bayes_dice_30_0.png","datePublished":"2021-08-09T15:53:06+00:00","breadcrumb":{"@id":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/#primaryimage","url":"https:\/\/allendowney.github.io\/ThinkBayes2\/_images\/bayes_dice_30_0.png","contentUrl":"https:\/\/allendowney.github.io\/ThinkBayes2\/_images\/bayes_dice_30_0.png"},{"@type":"BreadcrumbList","@id":"https:\/\/www.allendowney.com\/blog\/2021\/08\/09\/bayesian-dice\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.allendowney.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Bayesian Dice"}]},{"@type":"WebSite","@id":"https:\/\/www.allendowney.com\/blog\/#website","url":"https:\/\/www.allendowney.com\/blog\/","name":"Probably Overthinking It","description":"Data science, Bayesian Statistics, and other ideas","publisher":{"@id":"https:\/\/www.allendowney.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.allendowney.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.allendowney.com\/blog\/#organization","name":"Probably Overthinking It","url":"https:\/\/www.allendowney.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.allendowney.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.allendowney.com\/blog\/wp-content\/uploads\/2025\/03\/probably_logo.png","contentUrl":"https:\/\/www.allendowney.com\/blog\/wp-content\/uploads\/2025\/03\/probably_logo.png","width":714,"height":784,"caption":"Probably Overthinking It"},"image":{"@id":"https:\/\/www.allendowney.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/x.com\/AllenDowney","https:\/\/www.linkedin.com\/in\/allendowney\/","https:\/\/bsky.app\/profile\/allendowney.bsky.social"]},{"@type":"Person","@id":"https:\/\/www.allendowney.com\/blog\/#\/schema\/person\/4e5bfb2e9af6c3446cb0031a7bf83207","name":"AllenDowney","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/fb01b3a7f7190bea1bbf7f0852e686c2f8c03b099222df2ce4bc7926f15bcb43?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/fb01b3a7f7190bea1bbf7f0852e686c2f8c03b099222df2ce4bc7926f15bcb43?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/fb01b3a7f7190bea1bbf7f0852e686c2f8c03b099222df2ce4bc7926f15bcb43?s=96&d=mm&r=g","caption":"AllenDowney"},"url":"https:\/\/www.allendowney.com\/blog\/author\/allendowney_6dbrc4\/"}]}},"jetpack_publicize_connections":[],"jetpack_sharing_enabled":true,"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/www.allendowney.com\/blog\/wp-json\/wp\/v2\/posts\/659","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.allendowney.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.allendowney.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.allendowney.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.allendowney.com\/blog\/wp-json\/wp\/v2\/comments?post=659"}],"version-history":[{"count":1,"href":"https:\/\/www.allendowney.com\/blog\/wp-json\/wp\/v2\/posts\/659\/revisions"}],"predecessor-version":[{"id":660,"href":"https:\/\/www.allendowney.com\/blog\/wp-json\/wp\/v2\/posts\/659\/revisions\/660"}],"wp:attachment":[{"href":"https:\/\/www.allendowney.com\/blog\/wp-json\/wp\/v2\/media?parent=659"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.allendowney.com\/blog\/wp-json\/wp\/v2\/categories?post=659"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.allendowney.com\/blog\/wp-json\/wp\/v2\/tags?post=659"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}