Bitcoin is the most popular cryptocurrency nowadays due to its impressive returns, but investors still need to monitor its market trends as prices vary dramatically. This repository explores Bitcoin historical data, analyzes price trends, and performs time series analysis using RNN and LSTM neural networks to predict Bitcoin prices for the next 30 days.
- Comprehensive Data Analysis: Extensive exploration of Bitcoin historical data
- Dual Architecture: Implementation of both RNN and LSTM models
- Missing Data Handling: Automated data extraction using Selenium
- Time Series Forecasting: 30-day price prediction capabilities
- Rich Visualizations: Multiple charts and trend analysis
- Pre-trained Models: Ready-to-use trained models included
Bitcoin_price-prediction-using-RNN-and-LSTM/
βββ π bitcoin_price_predict.ipynb # Main analysis and prediction notebook
βββ π extract_data.ipynb # Data extraction using Selenium
βββ π bitcoinunix.csv # Scraped missing data
βββ π bitcoincharts.txt # Additional Bitcoin data
βββ π€ model/ # Trained models directory
β βββ timestamp_priceRNN.h5 # Trained RNN model
β βββ timeseries_price_LSTM.h5 # Trained LSTM model
βββ π¨ img/ # Visualization assets
β βββ site.png
β βββ rnn_back.png
β βββ rnn.gif
β βββ lstm_*.gif
βββ π requirements.txt # Project dependencies
- Python 3.7 or higher
- pip package manager
-
Clone the repository
git clone https://github.com/yourusername/Bitcoin_price-prediction-using-RNN-and-LSTM.git cd Bitcoin_price-prediction-using-RNN-and-LSTM -
Install dependencies
pip install -r requirements.txt
-
Launch Jupyter Notebook
jupyter notebook
-
Run the analysis
- Open
bitcoin_price_predict.ipynbfor main analysis and predictions - Open
extract_data.ipynbfor data extraction procedures
- Open
The dataset is sourced from Kaggle - Bitcoin Historical Data. Due to missing data entries, additional data extraction was performed using Selenium web scraping (see extract_data.ipynb).
Key Data Features:
- Historical Bitcoin prices (OHLCV data)
- Timestamp-based data points
- Over 4.8M+ data entries
- Missing data handled through web scraping
- Architecture: Basic RNN layers with dropout
- Purpose: Baseline time series prediction
- Model File:
model/timestamp_priceRNN.h5
- Architecture: LSTM layers with regularization
- Purpose: Advanced time series prediction with memory
- Model File:
model/timeseries_price_LSTM.h5
The models provide 30-day Bitcoin price predictions based on historical patterns and trends. Detailed analysis and visualizations are available in the main notebook.
Anuj Dev Singh
Machine Learning Engineer & AI Scientist
- Python 3.7+: Core programming language
- TensorFlow/Keras: Deep learning framework
- Pandas & NumPy: Data manipulation and analysis
- Matplotlib & Seaborn: Data visualization
- Scikit-learn: Machine learning utilities
- Selenium: Web scraping for missing data
This project is licensed under the MIT License - see the LICENSE file for details.
Contributions are welcome! Please feel free to submit a Pull Request.
For questions or suggestions, please open an issue in this repository.
β Star this repository if you found it helpful!