4. Strategy Adopted
1D convolution followed by Max pooling Layer is used as a feature extraction and
then feed into Artificial neural Network and the prediction.
Last 7 values of the close attribute is considered to predict the next close value.
5. Reason of the Strategy
CNN is best for automatic feature extraction for Artificial Neural Network.
After visualizing the correlation of the different attributes , considering only the last
7 days close value is enough to predict the next close value. So a 7X1 vector is
extracted from the dataset for the tanning and purpose.
Fig. 1 : Correlation of different attribute of Dataset
6. Implementation
Model and Tanning: 1D CNN with Fully Connected Artificial Neural Network is
used. Architecture of the model is as follows-
Input Shape : (7X1)
1D Convolution Layer with 64 filters of kernel size is 3 and activation is ‘relu’
1D MaxPooling Layer where pooling size is 2
Flatten
Dense Layer with 100 Neurons and activation is ‘relu’
Dense Layer with 1 Neurons and activation is ‘linear’
Loss : MSE , Metrics : MSE, Batch Size : 64 and Number of tanning Epoch is 5