From 32a22291bcc0205cf89d2a159664a603529ab5a3 Mon Sep 17 00:00:00 2001 From: Matvey Ezhov Date: Tue, 31 Jan 2017 19:18:45 +0300 Subject: [PATCH] Small `Doc.count_by` documentation update Current example doesn't work --- spacy/tokens/doc.pyx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spacy/tokens/doc.pyx b/spacy/tokens/doc.pyx index 8ce2c7fe4..805a5b30c 100644 --- a/spacy/tokens/doc.pyx +++ b/spacy/tokens/doc.pyx @@ -500,7 +500,8 @@ cdef class Doc: by the values of the given attribute ID. Example: - from spacy.en import English, attrs + from spacy.en import English + from spacy import attrs nlp = English() tokens = nlp(u'apple apple orange banana') tokens.count_by(attrs.ORTH)