Used a 40GB dataset made available by Avito via Kaggle to demonstrate how to handle big data for machine learning using limited memory. Instead of taking the incremental learning route to train a classifier, we used an intelligent technique to create a representative sample of the dataset. Since ad clicks are very rare events, naively sampling the data would have lead to significantly biased predictions. This sampling bias was addressed by assigning an importance weight to each data example selected. The resulting dataset could easily fit into memory and so was then trained using logistic regression.