BaşlayınÜcretsiz Başlayın

Systematic sampling

One sampling method that avoids randomness is called systematic sampling. Here, you pick rows from the population at regular intervals.

For example, if the population dataset had one thousand rows, and you wanted a sample size of five, you could pick rows 0, 200, 400, 600, and 800.

attrition_pop is available; pandas has been pre-loaded as pd.

Bu egzersiz

Sampling in Python

kursunun bir parçasıdır
Kursu Görüntüle

Uygulamalı interaktif egzersiz

Bu örnek kodu tamamlayarak bu egzersizi bitirin.

# Set the sample size to 70
sample_size = ____

# Calculate the population size from attrition_pop
pop_size = ____

# Calculate the interval
interval = ____
Kodu Düzenle ve Çalıştır