A geometric walkthrough of the mathematical foundations behind linear regression, reframed as a vector projection problem. Covers vectors, dot products, angles between vectors, and orthogonal projection using an intuitive highway-and-home analogy. Demonstrates how finding the best-fit line is equivalent to projecting a target vector onto a base vector, deriving the projection formula step by step. Part 1 of a two-part series; Part 2 will apply these concepts to solve an actual regression problem.

13m read timeFrom towardsdatascience.com
Post cover image
Table of contents
What is a Vector?Vector Projections

Sort: