New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing numpy import in episode 5 example #442

verdurin opened this Issue Jan 10, 2018 · 1 comment


None yet
1 participant

verdurin commented Jan 10, 2018

In the Checking our Data example code in episode 5, numpy is not imported, so as presented the code will fail:

NameError                                 Traceback (most recent call last)
<ipython-input-6-87d649e246a1> in <module>()
----> 1 data = numpy.loadtxt(fname='inflammation-01.csv', delimiter=',')
      2 if numpy.max(data, axis=0)[0] == 0 and numpy.max(data, axis=0)[20] == 20:
      3     print('Suspicious looking maxima!')
      4 elif numpy.sum(numpy.min(data, axis=0)) == 0:
      5     print('Minima add up to zero!')

NameError: name 'numpy' is not defined

import numpy should be added at the head of the example code for this section.


This comment has been minimized.

verdurin commented Jan 10, 2018

Actually, it applies to both examples in that section.

jeiros added a commit to jeiros/python-novice-inflammation that referenced this issue Jan 16, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment