# Unleashing the Power of Tweets and News in Stock-Price Prediction Using Machine-Learning Techniques
## 5 Results and Discussion
### Comparing the Impact of T and T+ Variables
\begin{table}
\begin{tabular}{c c c c c c c} \hline \hline
**NN** & **Test Set** & **Company** & **T RMSE** & **T+ RMSE** & **RMSE \(\pm\)** & **RMSE\(\pm\)** \\ \hline \multirow{8}{*}{\begin{tabular}{} \end{tabular} } & \multirow{8}{*}{\begin{tabular}{} \end{tabular} } & Amazon & 0.06246 & 0.06018 & 0.00228 & 4.0\% \\  & & Apple & 0.12860 & 0.12711 & 0.00149 & 1.0\% \\  & & Facebook & 0.07699 & 0.07392 & 0.00306 & 4.0\% \\  & & Ford & 0.13641 & 0.07553 & 0.06087 & 45.0\% \\  & & Google & 0.06271 & 0.04938 & 0.01333 & 21.0\% \\  & & Netflix & 0.11226 & 0.09216 & 0.02010 & 18.0\% \\  & & Tesla & 0.17632 & 0.18758 & \(-\)0.01126 & \(-\)6.0\% \\  & & Walmart & 0.05845 & 0.07278 & \(-\)0.01434 & \(-\)25.0\% \\ \hline \multirow{8}{*}{\begin{tabular}{} \end{tabular} } & \multirow{8}{*}{\begin{tabular}{} \end{tabular} } & Amazon & 0.04672 & 0.04210 & 0.00462 & 10.0\% \\  & & Apple & 0.05848 & 0.05299 & 0.00549 & 9.0\% \\  & & Facebook & 0.04404 & 0.03668 & 0.00737 & 17.0\% \\  & & Ford & 0.04024 & 0.03007 & 0.01017 & 25.0\% \\  & & Google & 0.03487 & 0.02874 & 0.00613 & 18.0\% \\  & & Netflix & 0.04211 & 0.03706 & 0.00505 & 12.0\% \\  & & Tesla & 0.05344 & 0.10091 & \(-\)0.04748 & \(-\)89.0\% \\  & & Walmart & 0.04021 & 0.04251 & \(-\)0.00231 & \(-\)6.0\% \\ \hline \multirow{8}{*}{\begin{tabular}{} \end{tabular} } & \multirow{8}{*}{\begin{tabular}{} \end{tabular} } & Amazon & 0.01950 & 0.01928 & 0.00022 & 1.0\% \\  & & Apple & 0.02188 & 0.02141 & 0.00047 & 2.0\% \\  & & Facebook & 0.02746 & 0.02407 & 0.00339 & 12.0\% \\  & & Ford & 0.16027 & 0.03661 & 0.12366 & 77.0\% \\  & & Google & 0.02388 & 0.02069 & 0.00320 & 13.0\% \\  & & Netflix & 0.02553 & 0.02399 & 0.00154 & 6.0\% \\  & & Tesla & 0.08409 & 0.04863 & 0.03546 & 42.0\% \\  & & Walmart & 0.01753 & 0.01814 & \(-\)0.00062 & \(-\)4.0\% \\ \hline \multirow{8}{*}{\
\begin{tabular}{} \end{tabular} } & \multirow{8}{*}{
\begin{tabular}{} \end{tabular} } & Amazon & 0.02602 & 0.02426 & 0.00176 & 7.0\% \\  & & Apple & 0.02002 & 0.01995 & 0.00007 & 0.0\% \\  & & Facebook & 0.02070 & 0.02193 & \(-\)0.00123 & \(-\)6.0\% \\ \cline{1-1}  & & Ford & 0.04886 & 0.02047 & 0.02839 & 58.0\% \\ \cline{1-1}  & & Google & 0.02355 & 0.02147 & 0.00209 & 9.0\% \\ \cline{1-1}  & & Netflix & 0.02954 & 0.02842 & 0.00113 & 4.0\% \\ \cline{1-1}  & & Tesla & 0.03610 & 0.03531 & 0.00079 & 2.0\% \\ \cline{1-1}  & & Walmart & 0.01278 & 0.01362 & \(-\)0.00085 & \(-\)7.0\% \\ \hline \hline \end{tabular}
\end{table} 
Table 5: The RMSE change when utilizing T vs. T+ variables. In general, within ML, a distinctive requirement involves training with a distinct dataset. It is necessary to thoroughly examine input variables across various stages of both the training and testing processes [165]. The objective is to assess the potential impact of the TC and NC variables on enhancing stock-price prediction. To this end, we conducted comparisons between these variables within the training data and across both test sets. The rationale behind this comparative analysis is to ascertain whether the pre-emptive examination of input data (prior to actual testing) could reveal the possibility of improving the accuracy of stock-price prediction by incorporating T+ variables into the model. Table 8 provides an analysis of the change in the CV between the training and the test sets. The CV for the variables exhibits relative stability across both the training and the test data for all models. Although CV is always non-negative, the change percentage can be positive or negative. Table 9 presents an analysis of the mean T+ variables across the training data, normal test set (nor-set), and panic test set (pan-set). Notably, there is a consistent improvement in RMSE across all eight tests with the inclusion of T+ variables. Among the top 50% of performers, there is an average 25% reduction in the mean TC between the training and test sets, suggesting that, on average, the TC is 25% lower in both test sets compared to the training set.