# R-squared

## Definition of R-squared

R-squared: R-squared is a statistic that measures how close the data points in a set are to a regression line (how well a model fits the data). It is a number between 0 and 1, with 1 indicating a perfect correlation and 0 indicating no correlation at all. It is calculated by taking the sum of the squares of the residuals divided by the total number of observations.