Skip to content

Commit 83e22ba

Browse files
authored
Clarify Seaborn install note and heatmap correlation explanation
1 parent ed460b5 commit 83e22ba

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

2-Regression/2-Data/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ To get charts to display useful data, you usually need to group the data somehow
199199

200200
Matplotlib is powerful, but it can take a lot of code to produce a polished chart. [Seaborn](https://seaborn.pydata.org/) is a library built _on top of_ Matplotlib that is designed for statistical data visualization. It works directly with Pandas dataframes, applies attractive default styles, and lets you create informative plots with far less code. Because Seaborn returns Matplotlib objects, you can still use everything you already know about Matplotlib to fine-tune the result.
201201

202-
> Seaborn is already included if you installed the packages in the previous lesson. If not, install it with `pip install seaborn`.
202+
> If you don't already have Seaborn installed, install it with `pip install seaborn`.
203203

204204
1. Import Seaborn at the top of the notebook, under the other imports. It is conventionally imported as `sns`:
205205

@@ -258,7 +258,7 @@ Scatter plots compare two variables at a time. When you have several numeric col
258258

259259
![A Seaborn heatmap showing correlations between the numeric columns](./images/heatmap.png)
260260

261-
Values close to `1` (or `-1`) mean the columns are strongly correlated. Notice how `Low Price` and `High Price` are almost perfectly correlated, while `Month` has very little correlation with price. ✅ What does that tell you about which columns are useful for predicting price?
261+
Values close to `1` (or `-1`) mean the columns are strongly _linearly_ correlated. Notice how `Low Price` and `High Price` are almost perfectly correlated. `Month`, on the other hand, shows only a weak linear correlation with price — even though the bar chart above revealed a clear seasonal peak in September and October. That's an important lesson: the correlation coefficient only measures _straight-line_ relationships, so it can miss seasonal or otherwise non-linear patterns. ✅ Why is it useful to look at both a heatmap *and* charts like the bar chart before deciding which columns to use?
262262

263263
### Matplotlib or Seaborn?
264264

0 commit comments

Comments
 (0)