title: NLTK and Stopwords Fail #lookuperror
body: <p>I am trying to start a project of sentiment analysis and I will use the stop words method. I made some research and I found that nltk have stopwords but when I execute the command there is an error.</p>
  
  <p>What I do is the following, in order to know which are the words that nltk use (like what you may found here <a href="http://www.nltk.org/book/ch02.html">http://www.nltk.org/book/ch02.html</a> in section4.1):</p>
  
  <pre><code>from nltk.corpus import stopwords
  stopwords.words('english')
  </code></pre>
  
  <p>But when I press enter I obtain</p>
  
  <pre><code>---------------------------------------------------------------------------
  LookupError                               Traceback (most recent call last)
  &lt;ipython-input-6-ff9cd17f22b2&gt; in &lt;module&gt;()
  ----&gt; 1 stopwords.words('english')
  
  C:\Users\Usuario\Anaconda\lib\site-packages\nltk\corpus\util.pyc in __getattr__(self, attr)
   66
   67     def __getattr__(self, attr):
  ---&gt; 68         self.__load()
   69         # This looks circular, but its not, since __load() changes our
   70         # __class__ to something new:
  
  C:\Users\Usuario\Anaconda\lib\site-packages\nltk\corpus\util.pyc in __load(self)
   54             except LookupError, e:
   55                 try: root = nltk.data.find('corpora/%s' % zip_name)
  ---&gt; 56                 except LookupError: raise e
   57
   58         # Load the corpus.
  
  LookupError:
  **********************************************************************
    Resource 'corpora/stopwords' not found.  Please use the NLTK
    Downloader to obtain the resource:  &gt;&gt;&gt; nltk.download()
    Searched in:
  - 'C:\\Users\\Meru/nltk_data'
  - 'C:\\nltk_data'
  - 'D:\\nltk_data'
  - 'E:\\nltk_data'
  - 'C:\\Users\\Meru\\Anaconda\\nltk_data'
  - 'C:\\Users\\Meru\\Anaconda\\lib\\nltk_data'
  - 'C:\\Users\\Meru\\AppData\\Roaming\\nltk_data'
  **********************************************************************
  </code></pre>
  
  <p>And, because of this problem things like this cannot run properly (obtaining the same error):</p>
  
  <pre><code>&gt;&gt;&gt; from nltk.corpus import stopwords
  &gt;&gt;&gt; stop = stopwords.words('english')
  &gt;&gt;&gt; sentence = "this is a foo bar sentence"
  &gt;&gt;&gt; print [i for i in sentence.split() if i not in stop]
  </code></pre>
  
  <p>Do you know what may be problem? I must use words in Spanish, do you recomend another method? I also thought using Goslate package with datasets in english</p>
  
  <p>Thanks for reading!</p>
  
  <p>P.D.: I use Ananconda</p>