arova-syams commited on
Commit
882de3a
·
verified ·
1 Parent(s): d960cf6

update readme

Browse files
Files changed (1) hide show
  1. README.md +124 -112
README.md CHANGED
@@ -1,113 +1,125 @@
1
- # Bitcoin Price Prediction with LSTM
2
-
3
- ## Project Overview
4
- This project aims to predict Bitcoin (BTC) prices for the next 60 days using a Long Short-Term Memory (LSTM) neural network. The dataset used contains historical BTC/USD prices from 2014 to early 2024. The project leverages PyTorch for deep learning and includes data preprocessing, feature engineering, and model evaluation.
5
-
6
- ---
7
-
8
- ## Table of Contents
9
- 1. [Introduction](#introduction)
10
- 2. [Dataset Description](#dataset-description)
11
- 3. [Project Workflow](#project-workflow)
12
- 4. [Model Architecture](#model-architecture)
13
- 5. [Results](#results)
14
- 6. [How to Run](#how-to-run)
15
- 7. [Future Work](#future-work)
16
- 8. [References](#references)
17
-
18
- ---
19
-
20
- ## Introduction
21
- Bitcoin is a highly volatile cryptocurrency, making price prediction a challenging task. This project uses sequential data modeling with LSTM to capture patterns in historical BTC prices and provide reliable predictions.
22
-
23
- ---
24
-
25
- ## Dataset Description
26
- - **Source**: Kaggle
27
- - **File**: `Dataset/BTC-USD.csv`
28
- - **Columns**: `Date`, `Open`, `High`, `Low`, `Close`, `Adj Close`, `Volume`
29
- - **Timeframe**: 2014 to early 2024
30
- - **Frequency**: Minute-level data aggregated to daily prices.
31
-
32
- ---
33
-
34
- ## Project Workflow
35
- ### 1. Data Preparation
36
- - Import libraries and load the dataset.
37
- - Perform initial exploration to understand the data structure.
38
-
39
- ### 2. Data Cleaning
40
- - Handle missing values and duplicates.
41
- - Normalize and standardize the data for better model performance.
42
-
43
- ### 3. Exploratory Data Analysis (EDA)
44
- - Visualize trends in BTC prices and trading volume.
45
- - Analyze correlations between features.
46
-
47
- ### 4. Feature Engineering
48
- - Create sequences of 30 days as input features.
49
- - Scale features using `MinMaxScaler`.
50
-
51
- ### 5. Modeling
52
- - Build LSTM and GRU models using PyTorch.
53
- - Train the models with Mean Squared Error (MSE) loss and Adam optimizer.
54
-
55
- ### 6. Evaluation
56
- - Evaluate the model using Root Mean Squared Error (RMSE).
57
- - Visualize predictions against actual prices.
58
-
59
- ### 7. Prediction
60
- - Predict BTC prices for the next 60 days.
61
- - Compare predictions with actual future prices.
62
-
63
- ---
64
-
65
- ## Model Architecture
66
- The LSTM model consists of:
67
- - **Input Layer**: Sequence of 30 days of closing prices.
68
- - **Hidden Layers**: 2 LSTM layers with 64 hidden units.
69
- - **Output Layer**: Single neuron for predicting the next day's price.
70
-
71
- ---
72
-
73
- ## Results
74
- - **LSTM Test RMSE**: ~1,118 USD
75
- - **GRU Test RMSE**: ~21,445 USD
76
- - The LSTM model outperformed the GRU model, demonstrating its ability to capture sequential patterns in BTC prices.
77
-
78
- ![Bitcoin Price Prediction](output_prediction.png)
79
-
80
- ---
81
-
82
- ## How to Run
83
- 1. Clone the repository:
84
- ```bash
85
- git clone <repository-url>
86
- cd Bitcoin-Prediction
87
- ```
88
-
89
- 2. Install dependencies:
90
- ```bash
91
- pip install -r requirements.txt
92
- ```
93
-
94
- 3. Run the Jupyter Notebook:
95
- ```bash
96
- jupyter notebook Notebook.ipynb
97
- ```
98
-
99
- 4. Follow the steps in the notebook to train the model and visualize predictions.
100
-
101
- ---
102
-
103
- ## Future Work
104
- - Add additional features such as macroeconomic indicators, Moving Average, RSI or sentiment analysis.
105
- - Perform hyperparameter tuning to further improve model performance.
106
- - Deploy the model as a web application for real-time predictions.
107
-
108
- ---
109
-
110
- ## References
111
- - Kaggle Dataset: [BTC-USD Historical Data](https://www.kaggle.com/)
112
- - PyTorch Documentation: [https://pytorch.org/](https://pytorch.org/)
 
 
 
 
 
 
 
 
 
 
 
 
113
  - CoinGecko API: [https://www.coingecko.com/](https://www.coingecko.com/)
 
1
+ ---
2
+ license: mit
3
+ language:
4
+ - en
5
+ metrics:
6
+ - mse
7
+ tags:
8
+ - LSTM
9
+ - PyTorch
10
+ - RNN
11
+ - DeepLearning
12
+ ---
13
+ # Bitcoin Price Prediction with LSTM
14
+
15
+ ## Project Overview
16
+ This project aims to predict Bitcoin (BTC) prices for the next 60 days using a Long Short-Term Memory (LSTM) neural network. The dataset used contains historical BTC/USD prices from 2014 to early 2024. The project leverages PyTorch for deep learning and includes data preprocessing, feature engineering, and model evaluation.
17
+
18
+ ---
19
+
20
+ ## Table of Contents
21
+ 1. [Introduction](#introduction)
22
+ 2. [Dataset Description](#dataset-description)
23
+ 3. [Project Workflow](#project-workflow)
24
+ 4. [Model Architecture](#model-architecture)
25
+ 5. [Results](#results)
26
+ 6. [How to Run](#how-to-run)
27
+ 7. [Future Work](#future-work)
28
+ 8. [References](#references)
29
+
30
+ ---
31
+
32
+ ## Introduction
33
+ Bitcoin is a highly volatile cryptocurrency, making price prediction a challenging task. This project uses sequential data modeling with LSTM to capture patterns in historical BTC prices and provide reliable predictions.
34
+
35
+ ---
36
+
37
+ ## Dataset Description
38
+ - **Source**: Kaggle
39
+ - **File**: `Dataset/BTC-USD.csv`
40
+ - **Columns**: `Date`, `Open`, `High`, `Low`, `Close`, `Adj Close`, `Volume`
41
+ - **Timeframe**: 2014 to early 2024
42
+ - **Frequency**: Minute-level data aggregated to daily prices.
43
+
44
+ ---
45
+
46
+ ## Project Workflow
47
+ ### 1. Data Preparation
48
+ - Import libraries and load the dataset.
49
+ - Perform initial exploration to understand the data structure.
50
+
51
+ ### 2. Data Cleaning
52
+ - Handle missing values and duplicates.
53
+ - Normalize and standardize the data for better model performance.
54
+
55
+ ### 3. Exploratory Data Analysis (EDA)
56
+ - Visualize trends in BTC prices and trading volume.
57
+ - Analyze correlations between features.
58
+
59
+ ### 4. Feature Engineering
60
+ - Create sequences of 30 days as input features.
61
+ - Scale features using `MinMaxScaler`.
62
+
63
+ ### 5. Modeling
64
+ - Build LSTM and GRU models using PyTorch.
65
+ - Train the models with Mean Squared Error (MSE) loss and Adam optimizer.
66
+
67
+ ### 6. Evaluation
68
+ - Evaluate the model using Root Mean Squared Error (RMSE).
69
+ - Visualize predictions against actual prices.
70
+
71
+ ### 7. Prediction
72
+ - Predict BTC prices for the next 60 days.
73
+ - Compare predictions with actual future prices.
74
+
75
+ ---
76
+
77
+ ## Model Architecture
78
+ The LSTM model consists of:
79
+ - **Input Layer**: Sequence of 30 days of closing prices.
80
+ - **Hidden Layers**: 2 LSTM layers with 64 hidden units.
81
+ - **Output Layer**: Single neuron for predicting the next day's price.
82
+
83
+ ---
84
+
85
+ ## Results
86
+ - **LSTM Test RMSE**: ~1,118 USD
87
+ - **GRU Test RMSE**: ~21,445 USD
88
+ - The LSTM model outperformed the GRU model, demonstrating its ability to capture sequential patterns in BTC prices.
89
+
90
+ ![Bitcoin Price Prediction](output_prediction.png)
91
+
92
+ ---
93
+
94
+ ## How to Run
95
+ 1. Clone the repository:
96
+ ```bash
97
+ git clone <repository-url>
98
+ cd Bitcoin-Prediction
99
+ ```
100
+
101
+ 2. Install dependencies:
102
+ ```bash
103
+ pip install -r requirements.txt
104
+ ```
105
+
106
+ 3. Run the Jupyter Notebook:
107
+ ```bash
108
+ jupyter notebook Notebook.ipynb
109
+ ```
110
+
111
+ 4. Follow the steps in the notebook to train the model and visualize predictions.
112
+
113
+ ---
114
+
115
+ ## Future Work
116
+ - Add additional features such as macroeconomic indicators, Moving Average, RSI or sentiment analysis.
117
+ - Perform hyperparameter tuning to further improve model performance.
118
+ - Deploy the model as a web application for real-time predictions.
119
+
120
+ ---
121
+
122
+ ## References
123
+ - Kaggle Dataset: [BTC-USD Historical Data](https://www.kaggle.com/)
124
+ - PyTorch Documentation: [https://pytorch.org/](https://pytorch.org/)
125
  - CoinGecko API: [https://www.coingecko.com/](https://www.coingecko.com/)