Computer Science I / Dot Product and Orthogonality
Practice question · True or false

Comparing documents by Euclidean distance between their word-count vectors makes the comparison independent of document length.

Hints
  1. What happens to the vector when a document is twice as long?
  2. Distance grows with magnitude; angle does not.
Show the answer

False

Why

False. Doubling every count doubles the vector's magnitude, so Euclidean distance grows even though the document is about the same thing. Cosine similarity looks only at the angle and is unaffected, which is why it is the standard for text, comparing what a document is about rather than how much of it there is.

Read the lesson: Dot Product and Orthogonality →

Practise Dot Product and Orthogonality

The app has 7 more questions on this lesson, and keeps your place in the course. Computer Science I is free to start.

More questions on Dot Product and Orthogonality