The prediction of the market value is of great importance to help in maximizing the profit of stock option purchase while keeping the risk low. Recurrent neural networks (RNN) have proved one of the most powerful models for processing sequential data. Long Short-Term memory is one of the most successful RNNs architectures. LSTM introduces the memory cell, a unit of computation that replaces traditional artificial neurons in the hidden layer of the network. With these memory cells, networks are able to effectively associate memories and input remote in time, hence suit to grasp the structure of data dynamically over time with high prediction capacity.
To train a model to get the prediction of "New York Stock Exchange" with respect to time further ahead We here has the value of 2016 whole year 80% of which value will be trained to valid with rest data and with this training we get model that will predict the further values
- Installed python version above 3.5
- Installed numpy
- Installed pandas
- Installed matploitlib
- Installed seaborn
- Installed Scipy and Sklearn
- Installed Keras
You can use the Jupyter noteook
- Download and unzip the files
- Set the path
- axis the file, through jupyter notebook
As the last graph predicts the stock exchange Prices with further ahead Time. The blue(actual) and Red(predicted) are having a minute difference. It's very efficient. The overall error here is calculated with Mean Square Error and it error value is 0.00707 for test data. Since the error is so small .Thus the model is working very properly and is usable.
- create a pull request if you have any other ways to increase the efficiency