gran4 / AI-InvestiBot

Innovative, high quality stock bot
MIT License
19 stars 6 forks source link

Testing Models with multiple features is bugged #5

Closed gran4 closed 1 year ago

gran4 commented 1 year ago

I believe it may be the fact that it has more than 1 feature. Maybe Close is differently structured from others?

gran4 commented 1 year ago

Traceback (most recent call last): File "/Users/ghur/Contributing/Stock-Bot-Predicter-AI/Models.py", line 361, in model.test() File "/Users/ghur/Contributing/Stock-Bot-Predicter-AI/Models.py", line 116, in test train_rmse = np.sqrt(mean_squared_error(train_data, train_predictions)) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/sklearn/metrics/_regression.py", line 442, in mean_squared_error y_type, y_true, y_pred, multioutput = _check_reg_targets( ^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/sklearn/metrics/_regression.py", line 100, in _check_reg_targets check_consistent_length(y_true, y_pred) File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/sklearn/utils/validation.py", line 397, in check_consistent_length raise ValueError( ValueError: Found input variables with inconsistent numbers of samples: [688, 628]

gran4 commented 1 year ago

Done.