Skip to the workspace
Pebellslearn by building
Types of Machine Learning  ›  Lesson

Unsupervised Learning

Unsupervised Learning 14 minUnsupervised learning works on data with no labels and looks for structure: groups of similar items, a few directions that capture most variation, or items that do not fit.

machine learning / Unsupervised Learning

Explore each scene at your own pace.

01 · The rule

The rule

Unsupervised Learning

The agency has 5,000 listings and a vague question: "What kinds of flats do we actually have?" Nobody has labelled them as "budget", "family" or "luxury", and nobody knows how many kinds there are. Unsupervised learning works exactly here, on data with no answer key.

The rule

No labels: the model finds structure, such as groups, directions or oddities.

Three jobs cover most unsupervised work:

  • Clustering: put similar items into groups. Flats might fall into small-and-cheap, mid-size-near-metro and large-and-pricey. k-means is the classic method: choose kk starting centres, assign every item to its nearest centre, move each centre to the average of its members, and repeat until nothing changes.
  • Dimensionality reduction: describe each item with fewer numbers while keeping most of the variation. Principal component analysis (PCA) uses the eigenvectors from the linear algebra section as new axes and keeps only the ones with the largest eigenvalues. Forty listing features might shrink to three, making the data easier to plot and faster to model.
  • Anomaly detection: flag items that fit no pattern. A listing claiming 40 m² for ₹80 thousand, on a street where similar flats rent for 14 to 16, stands out.

Because there are no labels, there is no accuracy score. You judge the result by whether it is useful: do the clusters make sense to the letting team, and do the flagged listings turn out to be errors or fraud?

Scene 1 of 5
Hover to wake the cannons. Drag to move, or use arrow keys when focused. Press Enter to fire a shot.