- Hands-On Mathematics for Deep Learning
- Jay Dawani
- 242字
- 2021-06-18 18:55:22
Sampling with or without replacement
Let's now assume that there is a total of n items in the bucket and we must pick r of them. Then, let R = {1, 2,…, r} be the list of items picked and let N = {1, 2, …, n} be the total number of items. This can be written as a function, as follows:

Here, f(i) is the ith item.
Sampling with replacement is when we pick an item at random and then put it back so that the item can be picked again.
However, sampling without replacement refers to when we choose an item and don't put it back, so we cannot pick it again. Let's see an example of both.
Say we need to open the door to our office and we have a bag containing n keys; they all look identical, so there's no way of differentiating between them.
The first time we try picking a key, we replace each one after trying it, and we manage to find the correct key on the rth trial, implying we got it wrong r-1 times. The probability is then as follows:

Now, we know that our earlier strategy wasn't the smartest, so this time we try it again but without replacement and eliminate each key that doesn't work. Now, the probability is as follows:

- 企業(yè)數(shù)字化創(chuàng)新引擎:企業(yè)級(jí)PaaS平臺(tái)HZERO
- MongoDB管理與開(kāi)發(fā)精要
- Visual Studio 2015 Cookbook(Second Edition)
- R數(shù)據(jù)科學(xué)實(shí)戰(zhàn):工具詳解與案例分析(鮮讀版)
- Lean Mobile App Development
- 白話(huà)大數(shù)據(jù)與機(jī)器學(xué)習(xí)
- 深入淺出 Hyperscan:高性能正則表達(dá)式算法原理與設(shè)計(jì)
- 大數(shù)據(jù)精準(zhǔn)挖掘
- Flutter Projects
- Oracle RAC日記
- INSTANT Android Fragmentation Management How-to
- 跨領(lǐng)域信息交換方法與技術(shù)(第二版)
- SAS金融數(shù)據(jù)挖掘與建模:系統(tǒng)方法與案例解析
- 大數(shù)據(jù)數(shù)學(xué)基礎(chǔ)(R語(yǔ)言描述)
- Node.js High Performance