Can a Cork café use the weather to predict how many iced drinks it will sell?
A Cork café records the afternoon temperature and the number of iced drinks it sells. Tomorrow is forecast to be fifteen degrees. The café has never recorded sales at exactly that temperature. How could you use the days it has recorded to make a prediction?
Read across the first row: at ten degrees, the café sold nineteen iced drinks. Each row pairs one afternoon's temperature with its sales. As you go down the table, sales rise. To see the pattern on a scatterplot, you'll turn each row into one point.
Look at the points first. They rise in a narrow band. Lay your ruler through the middle of that band, with points roughly balanced above and below along its length. That straight line is your line of best fit by eye. It can miss every point.
You're choosing between four ways to draw on that scatterplot. You want one straight line that represents the overall trend, even if it misses some points. Which approach should you use? Pick an answer.
Open paired statistics and choose linear regression. Enter the six original pairs, with temperature as x and sales as y. Read r, the correlation coefficient. It's about zero point nine eight six, close to positive one. That indicates a strong positive linear association. It doesn't prove that temperature caused the rise in sales.
Start at fifteen degrees on the horizontal axis. Go straight up to your line, then across to the vertical axis. This line gives about thirty-five drinks. Fifteen is between ten and twenty degrees, the lowest and highest recorded temperatures, so this is interpolation.
On the same line, the estimate at sixteen degrees is thirty-eight drinks, and at eighteen degrees it's forty-four. What estimate should you read from the line at seventeen degrees? Pick an answer.
At fifteen degrees, you're within the observed range and the points lie close to the line, so the estimate is reasonably well supported. At thirty-five degrees, you're far outside the range, with no observations nearby. That's extrapolation. Even a high r doesn't show that the trend continues that far.
If the question says, ‘Use your line of best fit to estimate sales at nineteen degrees’, read off about forty-seven drinks from this line. If it asks you to comment on reliability, give two pieces of evidence: nineteen is within the observed range and the points are close to the line.