Jupyter notebook name is not defined
<p>First of all a disclaimer: I am using python and anaconda and jupyter all for the first time, so it might be something basic.
I pasted the following code into a new Jupyter note from this url:
<a href="https://github.com/t0pep0/btc-e.api.python/blob/master/btceapi.py" rel="nofollow noreferrer">https://github.com/t0pep0/btc-e.api.python/blob/master/btceapi.py</a></p>

<p>After filling in my own API and secret API key, I tried to get this running:</p>

<pre><code>getInfo()
</code></pre>

<p>But I ran into this error:</p>

<pre><code>---------------------------------------------------------------------------
NameError                                 Traceback (most recent call last)
&lt;ipython-input-14-c63c8cc1259c&gt; in &lt;module&gt;()
     96 
     97 
---&gt; 98 getInfo()

NameError: name 'getInfo' is not defined
</code></pre>

<p>I checked the following solutions:</p>

<ul>
<li>Defining the function first and then running it, this example works
fine in Jupyter.
<a href="https://stackoverflow.com/questions/5986860/function-is-not-defined-error-in-python">function is not defined error in Python</a></li>
<li>Defining the class first and then running the function, this example
also works fine in Jupyter.
<a href="https://stackoverflow.com/questions/14804084/python-nameerror-name-is-not-defined">Python NameError: name is not defined</a></li>
</ul>

<p>But since the class and function are both defined in the correct order in the script I copied, there must be something else going on.</p>