Skip to content

Commit eb6bbed

Browse files
brownsarahmsstevens2maxim-belkin
authored
03-matplotlib.md: re-import data at start of plotting (#986)
Closes #876 Co-authored-by: Sarah Stevens <[email protected]> Co-authored-by: Maxim Belkin <[email protected]>
1 parent 2c2f8a4 commit eb6bbed

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

_episodes/03-matplotlib.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,20 @@ there is no official plotting library, `matplotlib` is the _de facto_ standard.
2020
import the `pyplot` module from `matplotlib` and use two of its functions to create and display a
2121
[heat map]({{ page.root }}/reference.html#heat-map) of our data:
2222

23+
> ## Episode Prerequisites
24+
>
25+
> If you are continuing in the same notebook from the previous episode, you already
26+
> have a `data` variable and have imported `numpy`. If you are starting a new
27+
> notebook at this point, you need the following two lines:
28+
>
29+
> ~~~
30+
> import numpy
31+
> data = numpy.loadtxt(fname='inflammation-01.csv', delimiter=',')
32+
> ~~~
33+
> {: .language-python}
34+
{: .prereq}
35+
36+
2337
~~~
2438
import matplotlib.pyplot
2539
image = matplotlib.pyplot.imshow(data)

0 commit comments

Comments
 (0)