Fixed small typo in documentation #57

Merged
merged 1 commit into from Sep 10, 2012

Projects

None yet

2 participants

@jkimbo
jkimbo commented Sep 3, 2012

Hey,

Love the library! Thank you for creating and maintaining it. Just thought I would fix a small problem with the documentation I came across today. When loading a classifier from a raw JSON string the JSON string needs to be parsed first or else it throws this error:

/home/jkimbo/code/categories/node_modules/natural/node_modules/apparatus/lib/apparatus/classifier/logistic_regression_classifier.js:174
    classifier.__proto__ = LogisticRegressionClassifier.prototype;
                         ^
TypeError: Cannot set property '__proto__' of undefined
    at Function.restore (/home/jkimbo/code/categories/node_modules/natural/node_modules/apparatus/lib/apparatus/classifier/logistic_regression_classifier.js:174:26)
    at Function.restore (/home/jkimbo/code/categories/node_modules/natural/lib/natural/classifiers/logistic_regression_classifier.js:37:67)
    at Query.output.load [as _callback] (/home/jkimbo/code/categories/ai.js:13:47)
    at Sequence.end (/home/jkimbo/code/categories/node_modules/mysql/lib/protocol/sequences/Sequence.js:68:22)
    at process.startup.processNextTick.process._tickCallback (node.js:244:9)

Thanks again!

Jonathan Kim Fixed small typo in documentation
When loading a classifier from a raw JSON string the JSON string needs
to be parsed first.
2920692
@chrisumbel chrisumbel merged commit 1c02c0d into NaturalNode:master Sep 10, 2012
@chrisumbel
Member

thanks!

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