Textstat não está executando funções

1

Acabei de encontrar o link sobre como instalar o textstat no meu python ocioso e obtive êxito para que ele funcionasse. No entanto, quando eu importo textstat tudo parece bem até que eu tente executar uma função. Ele continua me dizendo que essas não são funções definidas. Eu posso ir para a pasta textstat no meu computador, olhar o código e ver que eles estão definidos dentro do código. O que estou fazendo de errado?

Python 2.7.8 (default, Jul 13 2014, 17:11:32) 
[GCC 4.2.1 Compatible Apple LLVM 5.1 (clang-503.0.40)] on darwin
Type "copyright", "credits" or "license()" for more information.
>>> import textstat
>>> import nltk
>>> from nltk.book import
SyntaxError: invalid syntax
>>> from nltk.book import*
*** Introductory Examples for the NLTK Book ***
Loading text1, ..., text9 and sent1, ..., sent9
Type the name of the text or sentence to view it.
Type: 'texts()' or 'sents()' to list the materials.
text1: Moby Dick by Herman Melville 1851
text2: Sense and Sensibility by Jane Austen 1811
text3: The Book of Genesis
text4: Inaugural Address Corpus
text5: Chat Corpus
text6: Monty Python and the Holy Grail
text7: Wall Street Journal
text8: Personals Corpus
text9: The Man Who Was Thursday by G . K . Chesterton 1908
>>> flesch_reading_ease(text1)

Traceback (most recent call last):
  File "<pyshell#4>", line 1, in <module>
    flesch_reading_ease(text1)
NameError: name 'flesch_reading_ease' is not defined
>>> 
    
por Nathan D Moldenhauer 21.11.2014 / 20:51

0 respostas