Skip to content

Commit ff4f966

Browse files
committed
fixed issues with heatmap exercise
1 parent 566cc7d commit ff4f966

File tree

4 files changed

+149
-1634
lines changed

4 files changed

+149
-1634
lines changed

1-08E-DistplotExercises/Ex7-Distplot.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
# HINT:
2121
# This grabs the petal_length column for a particular flower
22-
# df[df['class']=='Iris-some-flower-class']['petal_length']
22+
df[df['class']=='Iris-some-flower-class']['petal_length']
2323

2424

2525

1-09E-HeatmapExercises/Sol8-Heatmap.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@
1010
# Perform imports here:
1111
import plotly.offline as pyo
1212
import plotly.graph_objs as go
13-
13+
import pandas as pd
1414
# Create a DataFrame from "flights" data
1515
df = pd.read_csv('../data/flights.csv')
1616

1717
# Define a data variable
1818
data = [go.Heatmap(
1919
x=df['year'],
2020
y=df['month'],
21-
z=df['passengers'].values.tolist()
21+
z=df['passengers']
2222
)]
2323

2424
# Define the layout

1-09E-HeatmapExercises/solution8.html

+1-1
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)