For example, we might wish to study the relationship between salt intake and blood pressure, in which case the above data might be the measured salt intake and blood pressure for n patients. It is always true that .
Correlation is unaffected by changes in scale.
This is a straightforward mathematical problem of minimizing a function of two variables. The answer is , where in which case the line is called the least-squares regression line . Many statistical packages automatically alert users to the presence of outliers and influential observations. Once detected, they should be examined carefully.