# An Intelligent Event-Sentiment-Based Daily Foreign Exchange Rate Forecasting System
## 4 Results and Discussion
### Results with Event Sentiments  
In this section, we discuss the results of exchange rate prediction using linear regression, support vector regression, and deep learning model in the presence of sentiments. We used social media tweets against mega-events in order to calculate the sentiment. Table 6 presents the results of exchange prediction in the presence of sentiments of mega-events that are related to Hong Kong. We considered the 2014 Hong Kong protest as a local event to predict the Hong Kong exchange rate. The 2012 US election was used as a global event to incorporate sentiment for exchange rate prediction. Results of all the three models show that _MAE_ and _RMSE_ were lower  
Figure 3: The plot of 50 forecasted and actual values of the foreign exchange rate of Hong Kong, Pakistan, and the UK considering linear, support vector, and deep learning model (without sentiment). LR: Linear regression, SVR: Support vector regression, DL: Deep learning. \begin{table}
\begin{tabular}{c c c c c c} \hline \hline
**Without** & \multicolumn{3}{c}{**Mean Absolute Error (MAE)**} & \multicolumn{3}{c}{**Root Mean Squared Error (RMSE)**} \\ \hline  & **Linear** & **Support Vector** & **Deep** & **Linear** & **Support Vector** & **Deep** \\  & **Regression** & **Regression** & **Learning** & **Regression** & **Regression** & **Learning** \\ \hline
**Final HK** & 0.018 \(\pm\) 0.018 & 0.017 \(\pm\) 0.024 & 0.017 \(\pm\) 0.017 & 0.025 \(\pm\) 0.000 & 0.029 \(\pm\) 0.000 & 0.024 \(\pm\) 0.000 \\
**Final Pak** & 9.042 \(\pm\) 7.902 & 8.687 \(\pm\) 8.285 & 7.636 \(\pm\) 6.952 & 12.008 \(\pm\) 0.000 & 12.004 \(\pm\) 0.000 & 10.327 \(\pm\) 0.000 \\
**Final UK** & 0.074 \(\pm\) 0.054 & 0.074 \(\pm\) 0.054 & 0.068 \(\pm\) 0.060 & 0.092 \(\pm\) 0.000 & 0.092 \(\pm\) 0.000 & 0.091 \(\pm\) 0.000 \\ \hline \hline \end{tabular}
\end{table} 
Table 5: Results for all the countries without event sentiments. when sentiment was incorporated in the model. Since _MAE_ and _RMSE_ were lower compared to the results calculated without sentiment, as a whole, the accuracy of exchange rate prediction improved because of sentiment. However, the impact of the 2014 Hong Kong protest was higher than that of the 2012 US election. Therefore, it is evident that the exchange rate of Hong Kong is more exposed to the local event. When a comparison is made within the models then support vector regression is more accurate in the case of _MAE_ for both the events. Furthermore, the deep learning model gives more reliable results of _RMSE_ in the case of Hong Kong protest sentiment. Figure 4 shows the graphical overview of the foreign exchange rate of Hong Kong by incorporating the sentiments of the Hong Kong protest and the US election. The plot considers 50 forecasted and actual values of the foreign exchange rate of Hong Kong with the sentiment of the Hong Kong protest and US election from top to bottom. All the predicted series were calculated using linear regression, support vector regression, and deep learning model. Since the plotted values of deep-learning-forecasted points are close to the actual in both the graphs of Hong Kong protest and US election, in the case of Hong Kong, the results of the deep learning model are more accurate as compared to those of linear regression. Table 7 presents the results of exchange prediction in the presence of sentiments of mega-events that are related to Pakistan. We considered the 2016 Lahore blast as a local event to predict the Pakistan exchange rate. The 2012 US election was used as a global event to incorporate sentiment for exchange rate prediction. Results of all the three models show that _MAE_ and _RMSE_ were lower when sentiments of mega-events were incorporated in the model. Since _MAE_ and _RMSE_ were lower compared to the results calculated without sentiment, as a whole, the accuracy of exchange rate prediction improved because of sentiment.