Update basic_maths.py (#1517)

* Update basic_maths.py

Add Doctests.

* Update basic_maths.py

* Add a space to fix the doctest
This commit is contained in:
percy07
2019-10-30 02:24:31 +05:30
committed by Christian Clauss
parent 4880e5479a
commit f8e97aa597
2 changed files with 26 additions and 28 deletions

View File

@ -90,7 +90,7 @@ class Perceptron:
>>> data = [[2.0149, 0.6192, 10.9263]]
>>> targets = [-1]
>>> perceptron = Perceptron(data,targets)
>>> perceptron.training() # doctest:+ELLIPSIS
>>> perceptron.training() # doctest: +ELLIPSIS
('\\nEpoch:\\n', ...)
...
>>> perceptron.sort([-0.6508, 0.1097, 4.0009]) # doctest: +ELLIPSIS