> For the complete documentation index, see [llms.txt](https://ikyathvarmadantuluri.gitbook.io/rnns/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://ikyathvarmadantuluri.gitbook.io/rnns/forecasting-stock-trends-using-rnns/untitled.md).

# Stock Trends Prediction using Bidirectional RNNs

For the same problem mentioned in LSTM Example, lets try to predict the prices using Bidirectional LSTM

{% content-ref url="/pages/-M5ejWShno1wFxeO50dT" %}
[Stock Trends Prediction using LSTM.](/rnns/forecasting-stock-trends-using-rnns/data.md)
{% endcontent-ref %}

Model Architecture of Bidirectional RNN

![](https://885410418-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M5eOOadDHYUcaYCn5CS%2F-M5gb3seS4XSClOiMcMC%2F-M5gbhQZRIokPz0yztdz%2FScreenshot%202020-04-24%20at%2010.36.25.png?alt=media\&token=96859dd8-99cd-4b2f-855f-87344773b523)

Below is the Actual vs Predicted trend in Apple Stock Prices using Bidirectional RNN

![](https://885410418-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M5eOOadDHYUcaYCn5CS%2F-M5gb3seS4XSClOiMcMC%2F-M5gbzjpVVC3qAw0a6U9%2FScreenshot%202020-04-24%20at%2010.38.05.png?alt=media\&token=8afe3a55-2a7c-4362-926a-4328628a3f07)

From the above graph, it is evident how closely we are able to predict the trend in the stocks using Bidirectional LSTM.

[Please find here from complete code Implementation](https://github.com/ikyath/RNN_Introduction_Fundamentals/blob/master/StockPrediction_Bidirectional.ipynb).
