Usage of random sampling

Random sampling procedures are a fundamental component of many analytic systems. You can, for example, use random sampling for selecting a test sample and a training sample for model building or machine learning.

You can also collect a smaller sample of the training set if the learning algorithm is complex. In either case, you would do the sampling without replacement.

Another method of sampling is when the learning methods are based on bootstrapping. Bootstrapping means that the random sampling is done with replacement. For this kind of sampling, you need many independent samples from the same data that are preferentially applied if the available data sets are small or for other reasons where the independence of the samples is essential.

You can also use sampling for promotion campaigns, for example, when you want only a representative set of customers to be the subjects of an action.

The random sampling procedure that is described here, creates a random sample of the rows of a table. By using it, you can get the exact number of rows in the sample, or you can let the system do a sampling of each row with a fixed probability. You can do random sampling with or without replacement.