Bootstrap is a resampling technique. It performs a sampling iteratively from the dataset with replacement. Sampling with replacement will make random selections. It requires the size of the sample and the number of iterations. In each iteration, it uniformly selects the records. Each record has equal chances of being selected again. The samples that are not selected are known as "out-of-bag" samples. Let's understand bootstrap using the following diagram:
In the preceding diagram, we can see that each element has an equal chance of selection in each bootstrap sample. Let's jump to another important topic of classification, which is classification model evaluation. The next topic helps us to assess the performance of the classification model.