官术网_书友最值得收藏!

Bayes' theorem

In this section, we will first introduce Bayes' theorem and demonstrate how it is applied in ML.

Bayes' theorem calculates the probability of an event given a condition, such that we have prior knowledge about the event, the condition, and the probability of the condition when the event occurs. In our snow prediction example, the event is when snow occurs. A condition would be when the temperature is between 20°F and 32°F. Based on the data, we can calculate the likelihood of temperature being 20°F and 32°F when it snows. Using this data, we can predict the probability of snow given the temperature being between 20°F and 32°F.

Assume that we have a class variable C and a condition variable x. Bayes' theorem is presented in formula 1. We also present a given simple way to remember different components of the algorithm in formula 2.

Formula 1:

   

Formula 2:

   

There are four terms that you need to remember from this formula.

主站蜘蛛池模板: 红桥区| 和平区| 普兰店市| 义乌市| 兴海县| 密山市| 清镇市| 沙田区| 黄骅市| 凭祥市| 阿坝县| 望谟县| 晴隆县| 聂荣县| 广汉市| 长治市| 新疆| 革吉县| 盐边县| 普宁市| 红河县| 东台市| 大关县| 沈阳市| 黄龙县| 康保县| 庐江县| 中阳县| 义乌市| 原平市| 广丰县| 延长县| 乐至县| 潢川县| 神农架林区| 喀喇沁旗| 靖江市| 乳源| 平果县| 化德县| 扶沟县|