- Hands-On Data Science and Python Machine Learning
- Frank Kane
- 421字
- 2021-07-15 17:15:12
Probability density functions
Let's talk about probability density functions, and we've used one of these already in the book. We just didn't call it that. Let's formalize some of the stuff that we've talked about. For example, we've seen the normal distribution a few times, and that is an example of a probability density function. The following figure is an example of a normal distribution curve

It's conceptually easy to try to think of this graph as the probability of a given value occurring, but that's a little bit misleading when you're talking about continuous data. Because there's an infinite number of actual possible data points in a continuous data distribution. There could be 0 or 0.001 or 0.00001 so the actual probability of a very specific value happening is very, very small, infinitely small. The probability density function really tells the probability of a given range of values occurring. So that's the way you've got to think about it.
So, for example, in the normal distribution shown in the above graph, between the mean (0) and one standard deviation from the mean (1σ) there's a 34.1% chance of a value falling in that range. You can tighten this up or spread it out as much as you want, figure out the actual values, but that's the way to think about a probability density function. For a given range of values it gives you a way of finding out the probability of that range occurring.
- You can see in the graph, as you get close to the mean (0), within one standard deviation (-1σ and 1σ), you're pretty likely to land there. I mean, if you add up 34.1 and 34.1, which equals to 68.2%, you get the probability of landing within one standard deviation of the mean.
- However, as you get between two and three standard deviations (-3σ to -2σ and 2σ to 3σ), we're down to just a little bit over 4% (4.2%, to be precise).
- As you get out beyond three standard deviations (-3σ and 3σ) then we're much less than 1%.
So, the graph is just a way to visualize and talk about the probabilities of the given data point happening. Again, a probability distribution function gives you the probability of a data point falling within some given range of a given value, and a normal function is just one example of a probability density function. We'll look at some more in a moment.
- Functional Python Programming
- TypeScript入門與實(shí)戰(zhàn)
- Oracle Exadata性能優(yōu)化
- jQuery EasyUI網(wǎng)站開發(fā)實(shí)戰(zhàn)
- Android 9 Development Cookbook(Third Edition)
- OpenShift在企業(yè)中的實(shí)踐:PaaS DevOps微服務(wù)(第2版)
- 網(wǎng)站構(gòu)建技術(shù)
- Python時(shí)間序列預(yù)測(cè)
- 精通Python自動(dòng)化編程
- MySQL從入門到精通(軟件開發(fā)視頻大講堂)
- C語(yǔ)言程序設(shè)計(jì)實(shí)訓(xùn)教程與水平考試指導(dǎo)
- Python期貨量化交易實(shí)戰(zhàn)
- Continuous Delivery and DevOps:A Quickstart Guide Second Edition
- 計(jì)算機(jī)常用算法與程序設(shè)計(jì)教程(第2版)
- 面向?qū)ο蠓治雠c設(shè)計(jì)(第3版)