Open cnubathula opened 5 years ago
I have this problem too but I solved it. You can view my pull request.
Thanks for update. as per pull request i have replace code but no luck iam getting below error.
Python 3.7.1 (default, Oct 28 2018, 08:39:03) [MSC v.1912 64 bit (AMD64)] :: Anaconda custom (64-bit) on win32 Type "help", "copyright", "credits" or "license" for more information.
from stocker import Traceback (most recent call last): File "
", line 1, in 1 ^ TabError: inconsistent use of tabs and spaces in indentationFile "C:\Users\687488\stocker\stocker.py", line 525 test['correct'] = (np.sign(test['pred_diff'][1:]) == np.sign(test['real_diff'][1:]))
inconsistent use of tabs and spaces in indentation
That is a little wired. Are you using the latest pull request?
It works fine on my computer and I can't see anything wrong with tabs or spaces.
Maybe you can try add [1:]
in the right place manually?
I am pretty sure that
RuntimeWarning: invalid value encountered in sign
This warning is caused by test['correct'] = (np.sign(test['pred_diff']) == np.sign(test['real_diff'])) * 1 ^
And by adding [1:]
begind test['']
will solve this.
Hi ,
Iam getting below errors while executing evaluate_prediction. iam new for python coding, could you please help to fix these errors.
Error Details:
See the caveats in the documentation: http://pandas.pydata.org/pandas-docs/stable/indexing.html#indexing-view-versus-copy test_pred_increase['pred_profit'] = prediction_profit You played the stock market in ITI from 2017-11-07 00:00:00 to 2018-11-07 00:00:00 with 1000 shares.
When the model predicted an increase, the price increased 42.01% of the time. When the model predicted a decrease, the price decreased 62.82% of the time.
The total profit using the Prophet model = $-37100.00. The Buy and Hold strategy profit = $-63100.00.
Thanks for playing the stock market!
C:\Users\687488\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib__init.py:886: MatplotlibDeprecationWarning: examples.directory is deprecated; in the future, examples will be found relative to the 'datapath' directory. "found relative to the 'datapath' directory.".format(key)) C:\Users\687488\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib\init.py:855: MatplotlibDeprecationWarning: examples.directory is deprecated; in the future, examples will be found relative to the 'datapath' directory. "found relative to the 'datapath' directory.".format(key)) C:\Users\687488\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib\init__.py:846: MatplotlibDeprecationWarning: The text.latex.unicode rcparam was deprecated in Matplotlib 2.2 and will be removed in 3.1. "2.2", name=key, obj_type="rcparam", addendum=addendum)