Blog » Bayesian Weighted Averages, and Why You Care


August 11, 2011 by


The search algorithms on CannaCentral.com were recently upgraded to utilize Bayesian weighted averages for results. When sorted, this is the value that is used rather than the actual rating of the specific result.

Why do we do this, and why should you care?

Let’s say there are two and only two dispensaries in given location. One has been in operation for years and is well liked. It has received 25 reviews, 20 of them five stars and five of them four stars for an average rating of 4.8. When you are viewing the detailed listing page, this is the most important because you aren’t comparing it to other results.

Now let’s say dispensary #2, which previously had no reviews is updated to include a single five star review. If we simply sorted by rating then this dispensary would be listed before the dispensary with a rating of 4.8 out of 25 reviews. This would be great if we knew that the second dispensary was worthy of a five star review, but what if that review came from the dispensary owner’s mom?

To sort all of this out so you don’t have to, we have implemented Bayesian weighted averages on the site using this algorithm:

This may look like Greek to you, but for you math fans out there, Wikipedia’s Bayesian average page describes this formula as following.

Calculating the Bayesian average uses the prior mean m and a constant C. C is assigned a value that is proportional to the typical data set size. The value is larger when the expected variation between data sets (within the larger population) is small. It is smaller, when the data sets are expected to vary substantially from one another.

Using CannaCentral’s 5 star rating system and the example from above, the first dispensary would receive a Bayesian value of 3.28 and the second dispensary a Bayesian value of 3.14 – although it has a lower rating a greater value is given to the number of reviews. The dispensary that has the highest weighted average is listed first. Magic!


2 Responses

  1. I agree! I am an old man (vietnam vet) and I am not interested in getting high just to get high. I have PTSD, Major Depressive Disorder, Anxiety Disorder, Sleep apnea and a few other maladies including elevated PSA, Chronic Chest pain to name a couple.

    I would like to find a reliable collective that lab tests their products and can ensure that I am getting something that is high in CBD relative to THC. The lower the THC the better for me. I could use a tad bit of THC to help with the depression, and anxiety; but everything I buy is in the double digits THC and comes with no information as to the CBD %. It is really frustrating. Requiring Dispenaries to pay for lab testing may even take the cost up a bit, but for me it would be worth it. I just ended up throwing away a gram of would be “sativa” with “low” THC although not lab tested or labeled as such. It was WAY high in THC if the way it hit me is any indication. Definitely NOT energetic or “mild” psychoactive characteristics. Anyone know of any reliable dispensaries in Riverside, San Bernardino, or San Diego Counties? thanks

    Report this comment

  2. Q1)It would be helpful if you could brief the calculations involved in deriving th and e scores 3.28 and 3.14 ?

    Q2)Also , are the scores 3.28 and 3.14 on a scale of 1-5 ?

    Report this comment



Leave a Reply

You must be logged in to post a comment.